1
0
Fork 0
forked from forgejo/forgejo

refactor PageData to pageData

This commit is contained in:
wxiaoguang 2021-10-14 18:12:40 +08:00
parent b0c049427b
commit f1eb3784d0
7 changed files with 9 additions and 9 deletions

View file

@ -36,7 +36,7 @@ Guidelines specialized for Gitea:
3. HTML ids and classes used in JavaScript should be unique for the whole project, and should contain 2-3 feature related keywords. We recommend to use the `js-` prefix for classes that are only used in JavaScript.
4. jQuery events across different features should use their own namespaces.
5. CSS styling for classes provided by frameworks should not be overwritten. Always use new class-names to overwrite framework styles. We recommend to use the `us-` prefix for user defined styles.
6. The backend can pass complex data to the frontend by using `ctx.PageData["myModuleData"] = map{}`
6. The backend can pass complex data to the frontend by using `ctx.PageData["myModuleData"] = map[]{}`
7. Simple pages and SEO-related pages use Go HTML Template render to generate static Fomantic-UI HTML output. Complex pages can use Vue2 (or Vue3 in future).
## Legacy Problems and Solutions