Skip to content

Commit

Permalink
build(ci): add app version workflow2
Browse files Browse the repository at this point in the history
  • Loading branch information
LincZero committed Feb 24, 2025
1 parent 8a02038 commit 2f42c8a
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/App/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/main.js"></script>
<script type="module" src="/src/main.ts"></script>
</body>
</html>
34 changes: 34 additions & 0 deletions src/App/src/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import { createApp } from 'vue';
import App from './App.vue';
// import './main.css'

// // 适配器
// import { nfSetting } from "../../NodeFlow/index"
// // @env [环境] md渲染, mdit版本
// import MarkdownIt from "markdown-it";
// const md = MarkdownIt()
// nfSetting.fn_renderMarkdown = ((markdown: string, el: HTMLElement, ctx?: any): void => {
// el.classList.add("markdown-rendered")

// const result: string = (md as MarkdownIt).render(markdown)
// const el_child = document.createElement("div"); el.appendChild(el_child); el_child.innerHTML = result;

// // 好像在Client端没办法获取到vuepress的md对象……
// // if (!nfSetting.md) {
// // console.warn("无法渲染markdown", nfSetting)
// // el.innerHTML = markdown
// // }
// // else {}
// })
// // @env [环境] http接口,其他环境版本。需要注意ob requestUrl和fetch的返回值不一样,前者还有一层status和json
// nfSetting.fn_request = async (
// url: string,
// method: string | undefined,
// headers: Record<string, string> | undefined,
// body: string | ArrayBuffer | undefined
// ) => {
// const responseData = await fetch(url, {method, headers, body});
// return responseData
// }

createApp(App).mount('#app');

0 comments on commit 2f42c8a

Please sign in to comment.