dart_to_js_script_rewriter
dart_to_js_script_rewriter copied to clipboard
A pub transformer that Rewrites Dart script tags to JavaScript script tags, eliminating 404s and speeding up initial loads. Use when building for deployment.
For your consideration. (I wasn't sure if I should be working under a non-master branch or not) Thanks.
Maybe this is a change in https://pub.dartlang.org/packages/markdown, but when I go to https://pub.dartlang.org/packages/dart_to_js_script_rewriter, the first paragraph of the README appears to be raw HTML: 
https://pub.dartlang.org/packages/dart_to_js_script_rewriter Makes it easy to see what's deployed, etc
The transformer also transforms html files in lib, this can give problems together with angular2 for example. It would be better I think if this would only transform files in...
Since `dart_to_js_script_rewriter` is already rewriting the tag it would be great if it automatically included a [subresource integrity](https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity) hash as well.
Even though I have reference to a single dart script, I get the following error on "release" build. ``` [Error from ScriptCompactor on Project|web/index.html]: Found either zero or multiple dart...
https://github.com/Workiva/dart_to_js_script_rewriter
This would help prevent that code is loaded synchronously, when the original program loaded the code after DOM Content loaded. See https://github.com/dart-lang/sdk/issues/24694 for an example.