layui render form form

Sometimes when the data requested by ajax is returned, the page is already loaded, and the content loaded by ajax cannot be displayed at this time. If you want to partially refresh the form, add the following code:

layui.use('form', function() {
var form = layui.form; //Only after this step is performed, some form elements will be automatically decorated successfully
form.render();
});

Just

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324791738&siteId=291194637