// top 页面 layui.use(['a', 'b'], function(){ var _tools = { func1: function() { console.log('func1'); } } _tools.func1(); window._tools = _tools; }) // iframe 页面 top._tools.func1();
原文:点击打开链接
// top 页面 layui.use(['a', 'b'], function(){ var _tools = { func1: function() { console.log('func1'); } } _tools.func1(); window._tools = _tools; }) // iframe 页面 top._tools.func1();
原文:点击打开链接