원클릭으로
spinder-page-routing
Create new pages and routes in the Spinder application, following the routing architecture and page component patterns.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Create new pages and routes in the Spinder application, following the routing architecture and page component patterns.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Create and manage expense categorization buckets in the Spinder app, including filtering logic and data aggregation.
Create new Lit-based components for the Spinder expense tracking app, following the project's coding standards and architecture patterns.
Debug issues in the Spinder expense tracking app, including transaction processing, UI rendering, and data flow problems.
Create, dispatch, and listen to custom events in the Spinder app using the Zod-validated event system.
Handle CSV parsing, transaction validation, and data processing for the Spinder expense tracking app.
Create new Zod-based type definitions for the Spinder expense tracking app, following the project's type organization patterns.
| name | spinder-page-routing |
| description | Create new pages and routes in the Spinder application, following the routing architecture and page component patterns. |
This skill helps add new pages and routes to the Spinder single-page application, ensuring proper integration with the routing system and component architecture.
Use this skill when you need to:
The Spinder routing system uses:
src/shared/type.routes.tssrc/shared/service.client.tssrc/client/page.<page-name>.tssrc/client/app.tssrc/client/app.tsIn src/shared/type.routes.ts, add your new route name:
export const RouteName = z.enum([
"home",
"csv_help",
"security",
"new_feature", // Add your new route name here
]);
Use snake_case for route names that will be converted to kebab-case for component names.
In src/shared/service.client.ts, add your route to the routes array:
export const routes = [
// ... existing routes
{
name: RouteName.enum.new_feature,
path: "/new-feature",
},
];
Create src/client/page.new-feature.ts:
import { css, html, TemplateResult } from "lit";
import { customElement } from "lit/decorators.js";
import { globalStyles } from "./styles.global.js";
import { SpinderAppProvider } from "./provider.app.js";
// Import any components you need
import "./component.some-component.js";
@customElement("spinder-new-feature-page")
export class SpinderNewFeaturePage extends SpinderAppProvider {
static override styles = [
globalStyles,
css`
main {
text-align: center;
}
/* Page-specific styles */
`,
];
override render(): TemplateResult {
return html`
<main>
<h1>New Feature</h1>
<!-- Your page content here -->
<spinder-some-component></spinder-some-component>
</main>
`;
}
}
Page components should:
SpinderAppProvider (or SpinderAbstractProvider if no app context needed)@customElement("spinder-<route-name>-page")globalStyles in static styles<main> element with page contentIn src/client/app.ts, add a case for your new route:
case RouteName.enum.new_feature:
return html`
<div class="app-bar"></div>
<spinder-new-feature-page></spinder-new-feature-page>
`;
Add this case within the switch statement in the render() method, before the default case.
In src/client/app.ts, add the import:
import "./page.new-feature.js";
Add this import alongside the other page imports at the top of the file.
To navigate to your new page:
import { NavigationEvent } from "./event.navigation.js";
import { dispatch } from "./util.events.js";
// Dispatch navigation event
dispatch(this, NavigationEvent("/new-feature"));
Or use regular anchor tags:
<a href="/new-feature">Go to New Feature</a>
For routes with parameters, use the route parsing system:
"/user/:id"parseRouteParams() to extract parametersPages automatically:
provider.load())