提交 ad27f7ca 编写于 作者: fxy060608's avatar fxy060608

no message

上级 71847843
...@@ -8,6 +8,13 @@ function isDebugMode () { ...@@ -8,6 +8,13 @@ function isDebugMode () {
return typeof __channelId__ === 'string' && __channelId__ return typeof __channelId__ === 'string' && __channelId__
} }
export function log (type) {
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
args[_key - 1] = arguments[_key]
}
console[type].apply(console, args)
}
export default function formatLog () { export default function formatLog () {
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) { for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key] args[_key] = arguments[_key]
......
...@@ -34,7 +34,7 @@ const uniCloudPath = path.resolve(__dirname, '../../packages/uni-cloud/dist/inde ...@@ -34,7 +34,7 @@ const uniCloudPath = path.resolve(__dirname, '../../packages/uni-cloud/dist/inde
function getProvides () { function getProvides () {
return { return {
'__f__': [path.resolve(__dirname, '../format-log.js'), 'default'], '__f__': [path.resolve(__dirname, '../format-log.js'), 'log'],
'uniCloud': [uniCloudPath, 'default'], 'uniCloud': [uniCloudPath, 'default'],
'wx.nextTick': [runtimePath, 'nextTick'], 'wx.nextTick': [runtimePath, 'nextTick'],
'Page': [runtimePath, 'Page'], 'Page': [runtimePath, 'Page'],
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册