mirror of
https://github.com/samuele-cozzi/obsidian-marp-slides.git
synced 2026-07-22 07:40:25 +00:00
feat: advanced html export
This commit is contained in:
parent
b79461be6b
commit
dc4b1667f2
4 changed files with 14 additions and 23 deletions
20
.github/workflows/release-please.yml
vendored
20
.github/workflows/release-please.yml
vendored
|
|
@ -117,23 +117,3 @@ jobs:
|
|||
asset_path: ./styles.css
|
||||
asset_name: styles.css
|
||||
asset_content_type: text/css
|
||||
- name: Upload styles.css
|
||||
id: upload-bespoke-js
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ needs.release-please.outputs.upload_url }}
|
||||
asset_path: ./node_modules/@marp-team/marp-cli/lib/bespoke.js
|
||||
asset_name: bespoke.js
|
||||
asset_content_type: text/javascript
|
||||
- name: Upload styles.css
|
||||
id: upload-watch-js
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ needs.release-please.outputs.upload_url }}
|
||||
asset_path: ./node_modules/@marp-team/marp-cli/lib/watch.js
|
||||
asset_name: watch.js
|
||||
asset_content_type: text/javascript
|
||||
|
|
|
|||
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -24,3 +24,5 @@ data.json
|
|||
tests/coverage
|
||||
|
||||
vault/.obsidian
|
||||
|
||||
lib
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import esbuild from "esbuild";
|
||||
import process from "process";
|
||||
import builtins from "builtin-modules";
|
||||
import { copy } from 'esbuild-plugin-copy';
|
||||
|
||||
const banner =
|
||||
`/*
|
||||
|
|
@ -39,8 +40,16 @@ const context = await esbuild.context({
|
|||
logLevel: "info",
|
||||
sourcemap: prod ? false : "inline",
|
||||
treeShaking: true,
|
||||
//outfile: "vault/.obsidian/plugins/obsidian-marp-slides/main.js", //for local dev!!!
|
||||
outfile: "main.js"
|
||||
outfile: "vault/.obsidian/plugins/obsidian-marp-slides/main.js", //for local dev!!!
|
||||
//outfile: "main.js",
|
||||
plugins: [
|
||||
copy({
|
||||
assets: {
|
||||
from: ['node_modules/@marp-team/marp-cli/lib/*'],
|
||||
to: ['./lib/'],
|
||||
}
|
||||
})
|
||||
]
|
||||
});
|
||||
|
||||
if (prod) {
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ export class FilePath {
|
|||
}
|
||||
|
||||
getResourcesPath(file: TFile) : string{
|
||||
const basePath = `${this.getRootPath(file)}/.obsidian/plugins/obsidian-marp-slides`;
|
||||
const basePath = `${this.getRootPath(file)}/.obsidian/plugins/obsidian-marp-slides/lib`;
|
||||
console.log(`Complete File Path: ${basePath}`);
|
||||
return basePath;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue