@bytedance/mona
Advanced tools
Comparing version 0.0.4 to 0.0.5
{ | ||
"name": "@bytedance/mona", | ||
"version": "0.0.4", | ||
"version": "0.0.5", | ||
"description": "Merchant app's developing and building tools", | ||
@@ -15,6 +15,2 @@ "main": "./dist/index", | ||
"license": "MIT", | ||
"dependencies": { | ||
"@bytedance/mona-plugin-events": "^0.0.3", | ||
"@bytedance/mona-runtime": "^0.0.4" | ||
}, | ||
"publishConfig": { | ||
@@ -24,3 +20,3 @@ "access": "public", | ||
}, | ||
"gitHead": "d89e169d306e1fef4a0bb7241abc7909c1019aec" | ||
"gitHead": "660ad56184422d2d54c686d62e0a52343289217d" | ||
} |
# mona | ||
对外暴露mona组件以及API | ||
## 组件 | ||
### Link | ||
跳转组件,支持插件/应用间页面跳转 | ||
#### 例子 | ||
```jsx | ||
import { Link } from '@bytedance/mona'; | ||
const Index = () => { | ||
return ( | ||
<div> | ||
<Link to="/pages/home/index">navigate to home </Link> | ||
</div> | ||
) | ||
} | ||
export default Index; | ||
``` | ||
#### 参数说明 | ||
| 参数 | 说明 | 是否必填 | 类型 | 默认值 | | ||
| ---- | ---- | ---- | ---- | ---- | | ||
| to | 要跳转的页面路由 | 是 | string | - | | ||
## API | ||
### navigateTo | ||
路由跳转,跳转到新的页面 | ||
#### 例子 | ||
```js | ||
import { navigateTo } from '@bytedance/mona'; | ||
navigateTo('/pages/home/index') | ||
``` | ||
### redirectTo | ||
路由重定向,跳转并替换当前页面路由 | ||
#### 例子 | ||
```js | ||
import { redirectTo } from '@bytedance/mona'; | ||
redirectTo('/pages/home/index') | ||
``` | ||
## 其他 | ||
对外暴露提供构建API | ||
## 配置创建 | ||
### createProjectConfig | ||
@@ -52,0 +5,0 @@ 创建项目配置,`mona.config.ts`中使用 |
Empty package
Supply chain riskPackage does not contain any code. It may be removed, is name squatting, or the result of a faulty package publish.
Found 1 instance in 1 package
6168
0
15
48
0
59
- Removed@bytedance/mona-plugin-events@^0.0.3
- Removed@bytedance/mona-runtime@^0.0.4
- Removed@babel/runtime@7.26.7(transitive)
- Removed@bytedance/mona-plugin-events@0.0.3(transitive)
- Removed@bytedance/mona-runtime@0.0.4(transitive)
- Removedhistory@4.10.1(transitive)
- Removedhoist-non-react-statics@3.3.2(transitive)
- Removedisarray@0.0.1(transitive)
- Removedjs-tokens@4.0.0(transitive)
- Removedloose-envify@1.4.0(transitive)
- Removedobject-assign@4.1.1(transitive)
- Removedpath-to-regexp@1.9.0(transitive)
- Removedprop-types@15.8.1(transitive)
- Removedreact@17.0.2(transitive)
- Removedreact-dom@17.0.2(transitive)
- Removedreact-is@16.13.1(transitive)
- Removedreact-router@5.3.4(transitive)
- Removedreact-router-dom@5.3.4(transitive)
- Removedregenerator-runtime@0.14.1(transitive)
- Removedresolve-pathname@3.0.0(transitive)
- Removedscheduler@0.20.2(transitive)
- Removedtiny-invariant@1.3.3(transitive)
- Removedtiny-warning@1.0.3(transitive)
- Removedvalue-equal@1.0.1(transitive)