Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
陈庄旺
uni-app
提交
64d3b9db
U
uni-app
项目概览
陈庄旺
/
uni-app
与 Fork 源项目一致
Fork自
DCloud / uni-app
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-app
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
64d3b9db
编写于
7月 15, 2019
作者:
fxy060608
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
refactor uni,create-instance-context
上级
2231d5df
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
16 addition
and
18 deletion
+16
-18
build/rollup.config.service.js
build/rollup.config.service.js
+6
-6
package.json
package.json
+5
-2
packages/uni-app-plus-nvue/dist/uni.js
packages/uni-app-plus-nvue/dist/uni.js
+0
-3
src/core/service/index.js
src/core/service/index.js
+1
-1
src/platforms/app-plus-nvue/helpers/get-real-path.js
src/platforms/app-plus-nvue/helpers/get-real-path.js
+2
-0
src/platforms/app-plus-nvue/service/constants.js
src/platforms/app-plus-nvue/service/constants.js
+0
-1
src/platforms/app-plus/service/uni/api.js
src/platforms/app-plus/service/uni/api.js
+0
-0
src/platforms/app-plus/service/uni/create-instance-context.js
...platforms/app-plus/service/uni/create-instance-context.js
+2
-2
src/platforms/app-plus/service/uni/index.js
src/platforms/app-plus/service/uni/index.js
+0
-3
未找到文件。
build/rollup.config.service.js
浏览文件 @
64d3b9db
const
path
=
require
(
'
path
'
)
const
alias
=
require
(
'
rollup-plugin-alias
'
)
const
replace
=
require
(
'
rollup-plugin-replace
'
)
const
replace
=
require
(
'
rollup-plugin-replace
'
)
const
requireContext
=
require
(
'
./rollup-plugin-require-context
'
)
let
input
=
'
src/platforms/app-plus
-nvue/service/index
.js
'
let
input
=
'
src/platforms/app-plus
/service/uni/create-instance-context
.js
'
const
output
=
{
file
:
'
packages/uni-app-plus-nvue/dist/index.js
'
,
...
...
@@ -14,7 +14,7 @@ if (process.env.UNI_SERVICE === 'legacy') {
input
=
'
src/platforms/app-plus-nvue/service/index.legacy.js
'
output
.
file
=
'
packages/uni-app-plus-nvue/dist/index.legacy.js
'
}
else
if
(
process
.
env
.
UNI_SERVICE
===
'
uni
'
)
{
input
=
'
src/platforms/app-plus/service/uni.js
'
input
=
'
src/platforms/app-plus/service/uni
/index
.js
'
output
.
file
=
'
packages/uni-app-plus-nvue/dist/uni.js
'
output
.
banner
=
'
export function createUniInstance(plus){
\n
'
output
.
footer
=
'
\n
return uni$1
\n
}
'
...
...
@@ -23,11 +23,11 @@ if (process.env.UNI_SERVICE === 'legacy') {
module
.
exports
=
{
input
,
output
,
plugins
:
[
plugins
:
[
requireContext
(),
alias
({
'
uni-core
'
:
path
.
resolve
(
__dirname
,
'
../src/core
'
),
'
uni-platform
'
:
path
.
resolve
(
__dirname
,
'
../src/platforms/
app-plus
'
),
'
uni-core
'
:
path
.
resolve
(
__dirname
,
'
../src/core
'
),
'
uni-platform
'
:
path
.
resolve
(
__dirname
,
'
../src/platforms/
'
+
process
.
env
.
UNI_PLATFORM
),
'
uni-platforms
'
:
path
.
resolve
(
__dirname
,
'
../src/platforms
'
),
'
uni-shared
'
:
path
.
resolve
(
__dirname
,
'
../src/shared/util.js
'
),
'
uni-helpers
'
:
path
.
resolve
(
__dirname
,
'
../src/core/helpers
'
)
...
...
package.json
浏览文件 @
64d3b9db
...
...
@@ -6,7 +6,10 @@
"dev:h5"
:
"npm run lint && cross-env NODE_ENV=production UNI_WATCH=true UNI_PLATFORM=h5 node build/build.js"
,
"build:h5"
:
"npm run lint && cross-env NODE_ENV=production UNI_WATCH=false UNI_PLATFORM=h5 node build/build.js"
,
"build:app-plus"
:
"cross-env UNI_PLATFORM=app-plus rollup -c build/rollup.config.js"
,
"build:service"
:
"npm run lint && UNI_SERVICE=uni rollup -c build/rollup.config.service.js && rollup -c build/rollup.config.service.js && UNI_SERVICE=legacy rollup -c build/rollup.config.service.js"
,
"build:uni:all"
:
"npm run lint && npm run build:uni && npm run build:uni:nvue && npm run build:uni:legacy"
,
"build:uni"
:
"UNI_PLATFORM=app-plus-nvue UNI_SERVICE=uni rollup -c build/rollup.config.service.js"
,
"build:uni:nvue"
:
"cross-env UNI_PLATFORM=app-plus-nvue rollup -c build/rollup.config.service.js"
,
"build:uni:legacy"
:
"cross-env UNI_PLATFORM=app-plus-nvue UNI_SERVICE=legacy rollup -c build/rollup.config.service.js"
,
"build:mp-qq"
:
"cross-env UNI_PLATFORM=mp-qq rollup -c build/rollup.config.js"
,
"build:mp-weixin"
:
"cross-env UNI_PLATFORM=mp-weixin rollup -c build/rollup.config.js"
,
"build:mp-baidu"
:
"cross-env UNI_PLATFORM=mp-baidu rollup -c build/rollup.config.js"
,
...
...
@@ -105,4 +108,4 @@
"main"
:
"index.js"
,
"description"
:
""
,
"author"
:
""
}
}
packages/uni-app-plus-nvue/dist/uni.js
浏览文件 @
64d3b9db
...
...
@@ -1823,9 +1823,6 @@ var api = /*#__PURE__*/Object.freeze({
const
uni$1
=
Object
.
create
(
null
);
/* eslint-disable no-undef */
uni$1
.
version
=
__VERSION__
;
Object
.
keys
(
api
).
forEach
(
name
=>
{
uni$1
[
name
]
=
promisify
(
name
,
wrapper
(
name
,
api
[
name
]));
});
...
...
src/core/service/index.js
浏览文件 @
64d3b9db
...
...
@@ -9,7 +9,7 @@ import {
import
todoApis
from
'
uni-platform/helpers/todo-api
'
import
baseApi
from
'
./api
'
import
baseApi
from
'
./api
/index
'
import
platformApi
from
'
uni-platform/service/api
'
...
...
src/platforms/app-plus-nvue/helpers/get-real-path.js
0 → 100644
浏览文件 @
64d3b9db
import
getRealPath
from
'
../../app-plus/helpers/get-real-path
'
export
default
getRealPath
src/platforms/app-plus-nvue/service/constants.js
已删除
100644 → 0
浏览文件 @
2231d5df
export
const
SHOW_ANISHOW
=
'
slide-in-right
'
src/platforms/app-plus/service/api.js
→
src/platforms/app-plus/service/
uni/
api.js
浏览文件 @
64d3b9db
文件已移动
src/platforms/app-plus
-nvue/service/index
.js
→
src/platforms/app-plus
/service/uni/create-instance-context
.js
浏览文件 @
64d3b9db
import
{
getApp
,
registerApp
}
from
'
.
/app
'
}
from
'
uni-platform/service
/app
'
import
{
getCurrentPages
}
from
'
.
/page
'
}
from
'
uni-platform/service
/page
'
import
{
createUniInstance
...
...
src/platforms/app-plus/service/uni.js
→
src/platforms/app-plus/service/uni
/index
.js
浏览文件 @
64d3b9db
...
...
@@ -10,9 +10,6 @@ import * as api from './api'
const
uni
=
Object
.
create
(
null
)
/* eslint-disable no-undef */
uni
.
version
=
__VERSION__
Object
.
keys
(
api
).
forEach
(
name
=>
{
uni
[
name
]
=
promisify
(
name
,
wrapper
(
name
,
api
[
name
]))
})
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录