Refactor SUI core to remove unnecessary code in BuildScripts function
This commit is contained in:
parent
fe247d1e28
commit
8b93c3b219
1 changed files with 0 additions and 4 deletions
|
|
@ -650,16 +650,12 @@ func (page *Page) BuildScripts(ctx *BuildContext, option *BuildOption, component
|
|||
code := string(source)
|
||||
if constants != "" {
|
||||
code = fmt.Sprintf("this.Constants = %s\n%s", constants, code)
|
||||
|
||||
}
|
||||
|
||||
parent := "body"
|
||||
if !ispage {
|
||||
parent = "head"
|
||||
code = fmt.Sprintf("function %s(){\n%s\n}\n", component, addTabToEachLine(code))
|
||||
if constants != "" {
|
||||
fmt.Println("page.Script.ConstantsToString", page.Route)
|
||||
}
|
||||
}
|
||||
|
||||
scripts = append(scripts, ScriptNode{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue