13 Commits

Author SHA1 Message Date
d5e08e4178 1.2.0 2020-03-31 00:16:40 +03:00
14e5c02a03 fireapp 2020-03-31 00:16:30 +03:00
ac1e2a4df3 1.1.0 2020-03-31 00:08:19 +03:00
Andrey Vlasov
0636ce1ff2 fix virtual module 2020-03-29 12:49:07 +03:00
Andrey Vlasov
47839a963c 1.0.5 2020-03-29 10:53:19 +03:00
Andrey Vlasov
3683151cb2 build 2020-03-29 10:52:08 +03:00
Andrey Vlasov
033865105f 1.0.4 2020-03-28 23:37:51 +03:00
Andrey Vlasov
556c31c56c add entry 2020-03-28 23:37:43 +03:00
Andrey Vlasov
a008842899 1.0.3 2020-03-28 23:33:09 +03:00
Andrey Vlasov
84cf7b72a0 rename virtual module 2020-03-28 23:32:35 +03:00
Andrey Vlasov
03eec8c836 change license 2020-03-28 23:08:24 +03:00
Andrey Vlasov
1f045701bf 1.0.2 2020-03-28 23:06:49 +03:00
Andrey Vlasov
a64221d659 add scope 2020-03-28 23:06:41 +03:00
5 changed files with 40 additions and 37 deletions

42
dist/index.js vendored

File diff suppressed because one or more lines are too long

View File

@@ -1,15 +1,15 @@
{ {
"name": "fire.app", "name": "@ijl/fire.app",
"version": "1.0.1", "version": "1.2.0",
"description": "", "description": "",
"main": "index.js", "main": "dist/index.js",
"scripts": { "scripts": {
"start": "nodemon ./stubs/server.js", "start": "nodemon ./stubs/server.js",
"build": "webpack --mode development", "build": "webpack --mode development",
"test": "echo \"Error: no test specified\" && exit 1" "test": "echo \"Error: no test specified\" && exit 1"
}, },
"author": "innoavvlasov@gmail.com", "author": "innoavvlasov@gmail.com",
"license": "MIT", "license": "ISC",
"devDependencies": { "devDependencies": {
"@types/node": "13.7.0", "@types/node": "13.7.0",
"@types/systemjs": "6.1.0", "@types/systemjs": "6.1.0",

View File

@@ -1,4 +1,4 @@
import "systemjs/dist/s"; import "systemjs/dist/system";
import "systemjs/dist/extras/amd"; import "systemjs/dist/extras/amd";
import "systemjs/dist/extras/named-register"; import "systemjs/dist/extras/named-register";
import "systemjs/dist/extras/named-exports"; import "systemjs/dist/extras/named-exports";

View File

@@ -1,12 +1,15 @@
export const defineVirtualModule = (params) => {
const virtualModule = createVirtualModule(params)
// @ts-ignore
global.define('root.scope.env', [], virtualModule)
}
const createVirtualModule = ({ config, navigations }) => ({ const createVirtualModule = ({ config, navigations }) => ({
getConfig: () => config, getConfig: () => config,
getConfigValue: (key) => config[key], getConfigValue: (key) => config[key],
getNavigations: () => navigations, getNavigations: () => navigations,
getNavigationsValue: (key) => navigations[key], getNavigationsValue: (key) => navigations[key],
}) })
export const defineVirtualModule = (params) => {
const virtualModule = createVirtualModule(params)
// @ts-ignore
System.set('root.scope', {
...virtualModule
});
}

View File

@@ -11,10 +11,10 @@ module.exports = {
index: "./src/main.ts" index: "./src/main.ts"
}, },
output: { output: {
library: "bootstrap", library: "fireapp",
path: path.resolve(__dirname, outputDirectory), path: path.resolve(__dirname, outputDirectory),
libraryExport: "default", libraryExport: "default",
publicPath: `/boorstrap/${pkg.version}/` publicPath: `/fireapp/${pkg.version}/`
}, },
plugins: [new CleanWebpackPlugin()], plugins: [new CleanWebpackPlugin()],