Skip to content

Commit

Permalink
Refactor decapcms
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewheberle committed Oct 3, 2024
1 parent 738e97c commit bf2ec2f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 9 deletions.
4 changes: 2 additions & 2 deletions decapcms/config.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
[module]

[[module.mounts]]
source = "layouts"
target = "layouts"
source = "layouts/decapcms.html"
target = "layouts/_default/decapcms-baseof.html.html"

[[module.mounts]]
source = "js"
Expand Down
6 changes: 1 addition & 5 deletions decapcms/js/decapcms.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,4 @@ window.CMS_MANUAL_INIT = true
import { init } from 'decap-cms-app'
import * as params from '@params'

if (params.config === undefined) {
init()
} else {
init(params.config)
}
init({config: params})
2 changes: 0 additions & 2 deletions decapcms/layouts/decapcms.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
<title>{{ .Title }}</title>
</head>
<body>
{{- block "main" . }}
{{- end }}
{{- $jsopts := (dict "minify" hugo.IsProduction) }}
{{- with .Site.Params.decapcms }}
{{- $jsopts = merge $jsopts (dict "params" .) }}
Expand Down

0 comments on commit bf2ec2f

Please sign in to comment.