Skip to content

Commit

Permalink
build: upgrade deps
Browse files Browse the repository at this point in the history
  • Loading branch information
HienTM committed Apr 29, 2020
1 parent ed44d54 commit ffaa83d
Show file tree
Hide file tree
Showing 3 changed files with 182 additions and 282 deletions.
14 changes: 7 additions & 7 deletions dist/index.es.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,23 @@ const getRegistries = () => {
return win._mfRegistries;
};

var f="_mfInfo";
var _="_mfInfo";

/* eslint-disable no-underscore-dangle */
const win = window;
const isLoadedAsMicroFrontend = (name) => { var _a; return name === ((_a = win[f]) === null || _a === void 0 ? void 0 : _a.name); };
const isLoadedAsMicroFrontend = (name) => { var _a; return name === ((_a = win[_]) === null || _a === void 0 ? void 0 : _a.name); };
const removeMicroFrontendInfo = (name) => {
var _a;
if (!name || ((_a = win[f]) === null || _a === void 0 ? void 0 : _a.name) === name) {
win[f] = undefined;
document.cookie = `${f}=; Max-Age=-99999999;`;
if (!name || ((_a = win[_]) === null || _a === void 0 ? void 0 : _a.name) === name) {
win[_] = undefined;
document.cookie = `${_}=; Max-Age=-99999999;`;
}
};
const setMicroFrontendInfo = (name, host) => {
const info = { host, name };
win[f] = info;
win[_] = info;
const expires = new Date(Date.now() + 10 * 365 * 24 * 60 * 60 * 1000);
document.cookie = `${f}=${JSON.stringify(info)}; expires=${expires.toUTCString()}; path=/`;
document.cookie = `${_}=${JSON.stringify(info)}; expires=${expires.toUTCString()}; path=/`;
};

const renderMicroFrontend = (name, history, microFrontendPath) => { var _a; return (_a = getRegistries().get(name)) === null || _a === void 0 ? void 0 : _a.render(history, microFrontendPath); };
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"type-check": "tsc --noEmit"
},
"dependencies": {
"cb-react-micro-frontend-core": "^0.0.3"
"cb-react-micro-frontend-core": "^0.0.5"
},
"devDependencies": {
"@commitlint/cli": "^8.3.5",
Expand All @@ -42,11 +42,11 @@
"eslint-config-react-ts": "^2.1.0",
"history": "^4.10.1",
"husky": "^4.2.3",
"lint-staged": "^10.0.8",
"lint-staged": "^10.2.0",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"react-router": "^5.1.2",
"release-it": "^13.0.2",
"release-it": "^13.5.7",
"rollup": "^2.7.3",
"rollup-plugin-cleanup": "^3.1.1",
"rollup-plugin-typescript2": "^0.27.0",
Expand Down
Loading

0 comments on commit ffaa83d

Please sign in to comment.