simple-render
v0.1.3
Published
Simple runtime renderer package.
Downloads
137
Readme
simple-render
Runtime renderer for Simple page documents.
Install
pnpm add simple-render vue element-plus @element-plus/icons-vue @vueuse/core json5Usage
import { SimplePreviewStatic } from 'simple-render';<template>
<SimplePreviewStatic
:document="pageDocument"
:api-definitions="apiDefinitions"
mode="preview"
/>
</template>For advanced control (custom runtime state/API bridge), you can still use SimplePreviewRoot with your own SimplePreviewRuntimeHost.
Events: route navigation
In DSL event handlers, the second argument supports simple.navigateTo(...):
- String path or full URL:
simple.navigateTo('/orders'),simple.navigateTo('https://example.com') - Object:
simple.navigateTo({ path: '/list', query: { page: 1 } })
By default this uses window.location (full page load). For Vue Router router.push, implement host.navigateTo(to, options) and call your router there.
