New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes in environment.js applied only on second save #8478
Comments
Hmm, I haven't seen/heard of this issue before now. I'll try to test tomorrow on OSX to see if the same thing is going on there and I just didn't notice... |
Thanks for looking into this, Robert. I didn't notice it before either. I checked one of my projects. When going back in time to Juli 2018 with ember-cli@3.3.0 everything worked as expected. In September 2018 I ugraded my app from ember-cli@3.3.0 to 3.4.2. The issue described above seems to start with this update. |
I noticed (using ember-cli@3.4.2) that broccoli is temporary creating files |
While investigating this issue I noticed that when removing the ember-cli/lib/models/project.js Lines 254 to 257 in c97dee8
changes in config/environment.js are applied on the first rebuild.
|
@nfc036 I confirm this behaviour. |
I'm experiencing the same behaviour. |
I have properties defined in
config/environment.js
, i.e.testProperty
with value 1:To illustrate the problem I import
ENV
from config in application controller and show the current value ofENV.testProperty
in the application template.Changing the value of
testProperty
from 1=>2 triggers a live reload, but the value shown in the browser is still "1" instead of "2" as expected. When changing the value from 2=>3, live reload is triggered again but not "3" as expected but "2" is shown (the value from the update before the last change).Additional information:
console.log(ENV.testProperty')
at the end ofconfig/environment.js
the console shows the (correct) current number twice before "Build successful".environment.js
is still not reflected in the application. I have to trigger a second save onenvironment.js
to get the correct content.ember s
always shows the current value correctly.I noticed this with ember-cli@3.8.1 but checking with ember-cli@3.7.1 shows the same behaviour. It might be relevant that I'm working on windows.
Output from
ember version --verbose && npm --version && yarn --version
:The text was updated successfully, but these errors were encountered: