Deno plugins (#42)

Switch from BoaJS to Deno core
This commit is contained in:
Gregory Schier
2024-06-07 10:47:41 -07:00
committed by GitHub
parent f43b38c893
commit acfc254a58
32 changed files with 1378 additions and 5663 deletions

View File

@@ -1,7 +1,7 @@
import xpath from 'xpath';
import { DOMParser } from '@xmldom/xmldom';
export function pluginHookResponseFilter(filter, text) {
export function pluginHookResponseFilter(ctx, filter, text) {
const doc = new DOMParser().parseFromString(text, 'text/xml');
const filtered = `${xpath.select(filter, doc)}`;
return { filtered };

View File

@@ -8,6 +8,8 @@ export default defineConfig({
fileName: 'index',
formats: ['es'],
},
outDir: resolve(__dirname, '../../src-tauri/plugins/filter-xpath'),
emptyOutDir: true,
sourcemap: true,
outDir: resolve(__dirname, 'build'),
},
});