obvious-core
Advanced tools
Comparing version 0.2.2-alpha to 0.2.2
@@ -6,2 +6,7 @@ # Changelog | ||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
## [0.2.2] - 2021-01-05 | ||
### Added | ||
- new API: socket.existsState | ||
- add umd bundle | ||
## [0.2.1] - 2020-12-10 | ||
@@ -8,0 +13,0 @@ ### Added |
@@ -0,0 +0,0 @@ import { Bus } from './lib/bus'; |
@@ -0,0 +0,0 @@ declare type CallbackType = (config?: any) => Promise<void>; |
@@ -0,0 +0,0 @@ import { Socket } from './socket'; |
@@ -0,0 +0,0 @@ import { Bus, MiddlewareType } from './bus'; |
@@ -0,0 +0,0 @@ import { CallbackType } from './types'; |
@@ -0,0 +0,0 @@ import { EventEmitter } from './event-emitter'; |
export declare type CallbackType = (...args: any[]) => void; |
@@ -0,0 +0,0 @@ export declare const Errors: { |
@@ -1,4 +0,4 @@ | ||
# <b>obvious.js</b> <small>0.1.1</small> | ||
# <b>obvious.js</b> <small>0.2.2</small> | ||
> 渐进式微前端框架 | ||
> 渐进式微前端库 | ||
@@ -5,0 +5,0 @@ - 简单,轻量 |
# 介绍 | ||
----------- | ||
obvious是一个渐进式微前端框架,在微前端架构中,obvious专注于解决前端微应用的依赖编排和应用间的通信问题,旨在通过简洁易懂,符合编程直觉的API以及灵活的中间件机制,帮助用户快速搭建好基础微前端体系,并支持进行更深层次地定制,从而实现完整可靠的微前端架构 | ||
obvious是一个渐进式微前端库,在微前端架构中,obvious专注于解决前端微应用的依赖编排和应用间的通信问题,旨在通过简洁易懂,符合编程直觉的API以及灵活的中间件机制,帮助用户快速搭建好基础微前端体系,并支持进行更深层次地定制,从而实现完整可靠的微前端架构 | ||
@@ -5,0 +5,0 @@ ## 关于微前端 |
{ | ||
"name": "obvious-core", | ||
"version": "0.2.2-alpha", | ||
"version": "0.2.2", | ||
"description": "a progressive micro front framework", | ||
"main": "./dist/index.js", | ||
"main": "./dist/index.umd.js", | ||
"module": "./dist/index.es.js", | ||
"types": "./dist/index.d.ts", | ||
"scripts": { | ||
"build": "tsc", | ||
"build": "rollup -c rollup.config.js", | ||
"lint": "eslint --fix --ext .ts,.js src", | ||
@@ -20,6 +22,8 @@ "docs": "docsify serve docs", | ||
"hooks": { | ||
"pre-commit": "npm run lint && npm run build && git add ." | ||
"pre-commit": "npm run lint && npm run build && git add ." | ||
} | ||
}, | ||
"devDependencies": { | ||
"@rollup/plugin-commonjs": "^17.0.0", | ||
"@rollup/plugin-node-resolve": "^11.0.1", | ||
"@types/jest": "^24.0.23", | ||
@@ -40,2 +44,4 @@ "@typescript-eslint/eslint-plugin": "^2.9.0", | ||
"node-fetch": "^2.6.1", | ||
"rollup": "^2.35.1", | ||
"rollup-plugin-typescript2": "^0.29.0", | ||
"ts-jest": "^24.2.0", | ||
@@ -45,3 +51,3 @@ "typescript": "^3.7.2" | ||
"dependencies": { | ||
"tslib": "^1.10.0" | ||
"tslib": "^2.0.3" | ||
}, | ||
@@ -48,0 +54,0 @@ "repository": { |
# obvious.js | ||
[![Coverage Status](https://coveralls.io/repos/github/ObviousJs/obvious-core/badge.svg?branch=master)](https://coveralls.io/github/ObviousJs/obvious-core?branch=master) [![release](https://img.shields.io/github/release/ObviousJs/obvious-core.svg)](https://github.com/ObviousJs/obvious-core/releases) [![lastCommit](https://img.shields.io/github/last-commit/ObviousJs/obvious-core)](https://github.com/ObviousJs/obvious-core/commits/master) [![](https://img.shields.io/badge/document-%E7%AE%80%E4%BD%93%E4%B8%AD%E6%96%87-brightgreen)](https://github.com/ObviousJs/obvious-core/blob/master/README.zh.md) | ||
Obvious is a progressive micro-front-end framework. In the micro-front-end architecture, Obvious focuses on solving the problem of orchestration and communication between micro frontend applications. It aims to help users quickly build a basic micro-front-end system and support deeper customization to achieve a complete and reliable micro-front-end architecture by providing easy-to-understand APIs and flexible middleware mechanisms. | ||
## Features | ||
- Provide flexible and convenient communication capabilities based on global status, event broadcast, and event unicast | ||
- Provide flexible and convenient communication capabilities based on global state, event broadcast, and event unicast | ||
- Support declaring dependencies when defining micro applications, and automatically activate dependencies when activating micro applications, allowing micro applications to be freely split and combine | ||
@@ -12,4 +14,10 @@ - Have a flexible middleware mechanism which allows developers to freely customize the unified registration and loading rules of resources in the form of writing middleware to realize automatic registration. At the same time, allow developers to write middleware to control the code excuting, so that developers can elegantly access log, js sandbox and other functions | ||
## Installation | ||
npm: | ||
`npm install obvious-core` | ||
umd: | ||
`<script src="https://unpkg.com/obvious-core@{version}/dist/index.umd.js"></script>` | ||
## Quick Start | ||
@@ -96,2 +104,2 @@ ![](docs/_media/tutorial-target.gif) | ||
## License | ||
obvious is [MIT Licensed](https://github.com/ObviousJs/obvious-core/blob/master/LICENSE) | ||
obvious is [MIT Licensed](https://github.com/ObviousJs/obvious-core/blob/master/LICENSE) |
@@ -54,5 +54,6 @@ import { EventEmitter } from './event-emitter'; | ||
const code = await res.text(); | ||
const fn = new Function(code); | ||
this.middleware?.handleExecute | ||
? this.middleware.handleExecute(code, src) | ||
: eval(code); | ||
: fn(); | ||
}; | ||
@@ -59,0 +60,0 @@ |
@@ -6,3 +6,3 @@ { | ||
"target": "es5", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */ | ||
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */ | ||
"module": "es2015", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */ | ||
"lib": ["ES6", "DOM", "ES2017"], /* Specify library files to be included in the compilation. */ | ||
@@ -13,2 +13,3 @@ "allowJs": false, /* Allow javascript files to be compiled. */ | ||
"declaration": true, /* Generates corresponding '.d.ts' file. */ | ||
"declarationDir": "./types", | ||
// "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ | ||
@@ -45,4 +46,6 @@ // "sourceMap": true, /* Generates corresponding '.map' file. */ | ||
// "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ | ||
// "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ | ||
// "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ | ||
"baseUrl": "./", /* Base directory to resolve non-absolute module names. */ | ||
"paths": { | ||
"tslib" : ["node_modules/tslib/tslib.d.ts"] | ||
}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ | ||
// "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */ | ||
@@ -49,0 +52,0 @@ // "typeRoots": [], /* List of folders to include type definitions from. */ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Uses eval
Supply chain riskPackage uses dynamic code execution (e.g., eval()), which is a dangerous practice. This can prevent the code from running in certain environments and increases the risk that the code may contain exploits or malicious behavior.
Found 1 instance in 1 package
5211454
2859
104
21
57
+ Addedtslib@2.8.1(transitive)
- Removedtslib@1.14.1(transitive)
Updatedtslib@^2.0.3