update webpack docs
Add FAQ, where we can add things as people run into problems Change-Id: I671bee6d53c845d66de7d65fd25baf46adb1d240 Reviewed-on: https://gerrit.instructure.com/71533 Reviewed-by: Clay Diffrient <cdiffrient@instructure.com> Product-Review: Ethan Vizitei <evizitei@instructure.com> QA-Review: Ethan Vizitei <evizitei@instructure.com> Tested-by: Ethan Vizitei <evizitei@instructure.com>
This commit is contained in:
parent
83d19fe6c7
commit
c5aed8b9df
|
@ -90,6 +90,20 @@ to run it headless in a container, so I run it with:
|
|||
which spools up the "js-tests" container specified in docker-compose.yml, which
|
||||
has an entry point that knows how to kick off karma with a headless runner.
|
||||
|
||||
### FAQ!
|
||||
|
||||
*I got some errors that look like "Cannot resolve module", but the module is totally there. What gives?*
|
||||
We do a lot of path rewriting to find things that are buried in extensible areas
|
||||
in canvas. If you're working with a plugin, look at frontend_build/CompiledReferencePlugin.js
|
||||
for an example of how we look at some require statements and rewrite them to find
|
||||
the right file; see if you can apply those ideas to your own loader if need be.
|
||||
|
||||
*Webpack says it can't find some "translations/" modules. What should I do?*
|
||||
Run `rake i18n:generate_js`. Webpack doesn't know how to generate the
|
||||
translations files yet, though we may tackle that in the future. For now
|
||||
that extract task needs to run before the first webpack build. When in doubt,
|
||||
just run `rake canvas:compile_assets` for a fully up to date build.
|
||||
|
||||
## TODO List (update as needed):
|
||||
|
||||
*TASK LIST*
|
||||
|
@ -333,17 +347,17 @@ used from "app/coffeescripts/ember/shared/components"
|
|||
[X] on building for production, fails with ProximityLoader ("ERROR in 232.bundle.js from UglifyJs
|
||||
Unexpected token: operator (!) [./frontend_build/jsHandlebarsHelpers.js!./frontend_build/pluginsJstLoader.js!./frontend_build/nonAmdLoader.js!./app/coffeescripts/util/ProximityLoader.coffee:111,6]")
|
||||
|
||||
[ ] Migrate requires that are in views to application js (check plugins like mra)
|
||||
[X] Migrate requires that are in views to application js (check plugins like mra)
|
||||
|
||||
|
||||
[ ] Delay returning tz in "timezone_plugin.js" until after promises have been run,
|
||||
[X] Delay returning tz in "timezone_plugin.js" until after promises have been run,
|
||||
or change how the rest of the app interacts with timezone_plugin so that we can
|
||||
return a promise, since async return is just not going to happen, and we need to have
|
||||
those promises done before using it.
|
||||
|
||||
[ ] sort out scopes for .app.app.coffeescripts.ember.shared.templates.components.ic_submission-download-dialog so that we don't need an awful exception in 18n.js
|
||||
|
||||
[ ] sniff test files automatically rather than configuring them manually in webpack_spec_index.js
|
||||
[X] sniff test files automatically rather than configuring them manually in webpack_spec_index.js
|
||||
|
||||
[ ] could get a nice performance boost out of reimplementing BrandableCSS.all_fingerprints_for(bundle)
|
||||
in node rather than shelling out to ruby for it
|
||||
|
|
Loading…
Reference in New Issue