Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

104
Views
Is there a way to modify a value in a JavaScript file with wix?

In installer we let the user insert the server address for the website. With an XmlFile it is not a problem. Here I use util:XmlFile

  <Component Id="Web.config" Guid="*" Directory="INSTALLFOLDER" Permanent="yes">
    <File Id="WebConfigFile" Name="Web.config" Source="..\Web\Web.config" KeyPath="yes" />
    <util:XmlFile
          Id="ServerAddress"
          Action="setValue"
          Permanent="yes"
          File="[INSTALLFOLDER]Web.config"
          SelectionLanguage="XPath"
          ElementPath="//configuration/appSettings/add[\[]@key='remotelocation'[\]]"
          Name="value"
          Value="[SERVER]"
          Sequence="1"/>
  </Component>

But at the current Website we store the server address in an env.js file.

Is it possible to change a js file with the same way as with the xml file?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!