This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/app/assets/javascripts/discourse
David Taylor 7fdb2944b9
DEV: Allow ember server --environment production to be used (#15431)
Running in production mode is useful when doing performance-sensitive work.

- Set the `exportApplicationGlobal` flag, so we get the `Discourse` global in production mode. It defaults to only adding the global in development mode. Note that, when generating ember-cli assets via rails, we set this in `ApplicationHelper#discourse_config_environment`.

- Disable SRI - Ember CLI adds this to index.html when in production mode. We don't use SRI in production, so disable here to match.

- Refactor the `AssetRev` logic in `ember-cli-build.js`, so that our custom bundle hashes are find/replaced into index.html. Without this change, our custom bundles (e.g. `start-discourse.js`) remain without their hash in `index.html`, and do not function.

  I have confirmed that the only diff in the `/dist` out following this change is to the `index.html` file. All other filenames and contents remain identical.
2021-12-31 12:26:23 +00:00
..
app check for code-blocks before loading highlight-js 2021-12-30 12:44:22 -05:00
config DEV: Allow ember server --environment production to be used (#15431) 2021-12-31 12:26:23 +00:00
lib DEV: Ensure redirects are passed through to the client by ember-cli (#15170) 2021-12-02 15:03:45 +00:00
public/assets/scripts FIX: Don't try to boot the ember app on old browsers (#14423) 2021-09-22 16:54:57 -03:00
tests FEATURE: allow sending message via a link to multiple users (#15412) 2021-12-28 06:35:22 +05:30
.ember-cli REFACTOR: Sync up master with changes for Ember-CLI (#11671) 2021-01-12 10:13:21 -05:00
.npmrc DEV: Prevent npm usage (#13945) 2021-08-04 22:04:58 +02:00
ember-cli-build.js DEV: Allow ember server --environment production to be used (#15431) 2021-12-31 12:26:23 +00:00
package.json SECURITY: Remove ember-cli specific response from application routes (#15155) 2021-12-01 16:10:40 +00:00
testem.js DEV: Increase Chrome memory limit (#14918) 2021-11-13 15:32:16 +01:00