mirror of
https://github.com/flarum/framework.git
synced 2025-01-19 18:12:59 +08:00
Use System.get instead of System.import
Means we get drop Promise polyfill
This commit is contained in:
parent
de610eac35
commit
d82da543b4
|
@ -9,7 +9,6 @@
|
|||
"color-thief": "v2.0",
|
||||
"mithril": "lhorie/mithril.js#next",
|
||||
"es6-micro-loader": "caridy/es6-micro-loader#v0.2.1",
|
||||
"es6-promise-polyfill": "~1.0.0",
|
||||
"fastclick": "~1.0.6"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -7,7 +7,6 @@ gulp({
|
|||
files: [
|
||||
nodeDir + '/babel-core/external-helpers.js',
|
||||
|
||||
bowerDir + '/es6-promise-polyfill/promise.js',
|
||||
bowerDir + '/es6-micro-loader/dist/system-polyfill.js',
|
||||
|
||||
bowerDir + '/mithril/mithril.js',
|
||||
|
|
|
@ -26,10 +26,8 @@
|
|||
@endforeach
|
||||
|
||||
<script>
|
||||
var app;
|
||||
System.import('flarum/app').then(function(module) {
|
||||
try {
|
||||
app = module.default;
|
||||
var app = System.get('flarum/app').default;
|
||||
app.preload = {
|
||||
data: {!! json_encode($data) !!},
|
||||
document: {!! json_encode($document) !!},
|
||||
|
@ -45,7 +43,6 @@
|
|||
document.write('<div class="container">Something went wrong.</div>');
|
||||
throw e;
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
@if ($content)
|
||||
|
|
Loading…
Reference in New Issue
Block a user