ui: code formatting with wastyle

This commit is contained in:
undefined committed 2021-04-15 13:49:33 +08:00
1 parent 496ce16dce
commit b052e2aa78
7 files changed
+64 -25

No files matched your search

@@ -0,0 +1,12 @@
import astyleBinaryUrl from 'wastyle/dist/astyle-optimize-size.wasm';
export default async function load() {
const { init, format } = await import('wastyle');
try {
await init(astyleBinaryUrl);
console.log('WAstyle is ready!');
return [true, format];
} catch (e) {
return [false, e.message];
}
}