Registry / productivity / pixi-framework

pixi-framework

JSON →
library0.16.5jsnpmunverified

Pixi Framework is a lightweight, TypeScript-first frontend framework for building reactive web applications. Version 0.16.5 is the latest stable release, with periodic updates. It offers a minimal API with reactive state management and a virtual DOM, positioning itself as a simpler alternative to libraries like React or Vue for small to medium projects. It is ESM-only and enforces type safety through TypeScript definitions.

npm install pixi-framework
INSTALL
IMPORT
SIG · PIXI-FRAMEWORK
P
pixi-framework
productivityjavascriptv0.16.5
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

createApp
import { createApp } from 'pixi-framework'
const createApp = require('pixi-framework')
ESM-only since v0.15. CommonJS require() will fail.
reactive
import { reactive } from 'pixi-framework'
import { reactive } from 'pixi-framework/reactive'
reactive is a named export, not a submodule.
defineComponent
import { defineComponent } from 'pixi-framework'
import defineComponent from 'pixi-framework'
defineComponent is a named export, not a default export.

This example creates a reactive state object, initializes an app with a template that renders the count, and mounts it to the DOM element with id 'app'.

import { createApp, reactive } from 'pixi-framework' const state = reactive({ count: 0 }) const app = createApp({ template: ({ count }) => `<div>${count}</div>`, state }) app.mount('#app')
Debug
Known issues
breakingESM-only: CommonJS require() is not supported since v0.15. Use ESM imports only.
fix
Convert to ESM: use import statements instead of require().
affects: >=0.15
deprecatedThe `createApp` function signature changed in v0.16. Previously accepted an object with `render` key, now uses `template`.
fix
Replace `render` with `template` in createApp configuration.
affects: >=0.16
gotchaReactive state must be declared before createApp. Mutating state after creation will not trigger re-renders.
fix
Initialize all reactive state before calling createApp.
affects: >=0.13
breakingVirtual DOM library was replaced in v0.14, breaking custom directives that relied on previous vnode structure.
fix
Update custom directives to use new vnode interface as per migration guide.
affects: >=0.14
Errors
Common errors & fixes
SyntaxError: Cannot use import statement outside a module
Using ESM import in a CommonJS context, e.g., Node.js without "type": "module" in package.json, or in a browser without <script type="module">.
fix
Add "type": "module" to your package.json, or use .mjs extension, or in browsers use <script type="module">.
TypeError: createApp is not a function
Incorrect import: treating named export as default export, or using require() in ESM-only version.
fix
Use `import { createApp } from 'pixi-framework'` instead of `import createApp from 'pixi-framework'`.
Upgrade
Version history
0.16.5latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
32 hits · last 30 days
node
28
Amazon
1
OpenAI (training)
1
Resources
pixi-framework — npm install pixi-framework · libregistry