@stackflow/plugin-renderer-basic
이 플러그인은 스택 상태를 기반으로 액티비티를 기본적으로 렌더링하는 데 사용되어요.
설치
npm install @stackflow/plugin-renderer-basic사용법
stackflow.config.ts
import { defineConfig } from "@stackflow/config";
export const config = defineConfig({
activities: [
{
name: "MyHome",
route: "/",
},
{
name: "MyArticle",
route: "/articles/:articleId",
},
],
});stackflow.ts
import { stackflow } from "@stackflow/react";
import { basicRendererPlugin } from "@stackflow/plugin-renderer-basic";
import { config } from "./stackflow.config";
import { MyHome } from "./MyHome";
import { MyArticle } from "./MyArticle";
const { Stack } = stackflow({
config,
components: {
MyHome,
MyArticle,
},
plugins: [basicRendererPlugin()],
});