20 lines
396 B
JavaScript
20 lines
396 B
JavaScript
const information = {
|
|
debug: true,
|
|
baseUrl: 'http://localhost:8080',
|
|
}
|
|
|
|
export function amisRender(target, amisJson) {
|
|
let amisJsonObject = amisJson(information)
|
|
if (information.debug) {
|
|
console.log(amisJsonObject)
|
|
}
|
|
amisRequire('amis/embed').embed(
|
|
target,
|
|
amisJsonObject,
|
|
information,
|
|
{
|
|
theme: 'antd',
|
|
enableAMISDebug: information.debug,
|
|
},
|
|
)
|
|
} |