Registry / web-framework / eustia-component

eustia-component

JSON →
library0.0.3jsnpmunverified

A transpiler plugin for the Eustia build tool that converts HTML files containing inline styles, templates, and scripts into pure JavaScript modules. Version 0.0.3 is the latest release. It is designed for use with Eustia to simplify authoring reusable UI components with HTML and CSS, without relying on web components. The transpiler extracts CSS into a string variable, HTML templates into string variables, and concatenates script content, providing a simple component pattern for library authors.

npm install eustia-component
INSTALL
IMPORT
SIG · EUSTIA-COMPONENT
E
eustia-component
web-frameworkjavascriptv0.0.3
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.

eustia-component
const eustiaComponent = require('eustia-component')
const eustiaComponent = require('eustia-component')()
The package exports a function that should be called to create a handler, not the handler itself.
handler
handler: require('eustia-component')()
handler: require('eustia-component')
You must invoke the function with no arguments to get the transpiler handler.
EustiaComponent
import eustiaComponent from 'eustia-component'
import { eustiaComponent } from 'eustia-component'
This package only supports CommonJS; use require() or default import in TypeScript with esModuleInterop.

Shows how to configure Eustia to use eustia-component as a transpiler for .html files.

// eustia.config.js module.exports = { util: { files: 'index.html', extension: ['js', 'html'], transpiler: [ { test: /\.html$/, handler: require('eustia-component')() } ] } };
Debug
Known issues
deprecatedPackage is very low version and rarely updated; may not be maintained for future Eustia versions.
fix
Consider using modern component frameworks like Vue or React if Eustia support is discontinued.
affects: >=0.0.0
gotchaThe exported function must be called with no arguments to get the transpiler handler; directly using require('eustia-component') as handler will fail.
fix
Use handler: require('eustia-component')()
affects: >=0.0.0
gotchaThe plugin only works within the Eustia build system; it is not a standalone HTML-to-JS converter.
fix
Ensure Eustia is properly configured in your project.
affects: >=0.0.0
Errors
Common errors & fixes
Error: Cannot find module 'eustia-component'
Package not installed or missing in node_modules.
fix
Run 'npm install eustia-component'
TypeError: handler is not a function
Using require('eustia-component') instead of require('eustia-component')().
fix
Change handler: require('eustia-component') to handler: require('eustia-component')()
Upgrade
Version history
0.0.3latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
2 hits · last 30 days
node
2
Resources
eustia-component — npm install eustia-component · libregistry