Registry / web-framework / appbot-compiler

appbot-compiler

JSON →
library0.0.19jsnpmunverified

Experimental CommonJS module compiler for target-specific modular design, enabling device-tailored app versions from a shared codebase. Current version 0.0.19 (unstable, low release cadence). Dynamically compiles CommonJS modules based on screen width or device type, serving conditional bundles (e.g., mobile vs web). A proof-of-concept for server-side module compilation with query parameter routing, not production-ready. Differentiators: runtime module assembly per device, mirror module names across targets. Risks: no active maintenance, no security audits, single author.

npm install appbot-compiler
INSTALL
IMPORT
SIG · APPBOT-COMPILER
A
appbot-compiler
web-frameworkjavascriptv0.0.19
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.

Compiler
import { Compiler } from 'appbot-compiler'
const Compiler = require('appbot-compiler')
Package is experimental; no stable ESM/CJS module.
compile
import { compile } from 'appbot-compiler'
import compile from 'appbot-compiler'
Named export only; default export does not exist.
require
const appbot = require('appbot-compiler')
import * as appbot from 'appbot-compiler'
CommonJS only; no ESM support. Use require.

Shows how to compile a CommonJS app for mobile target with width query parameter.

const { compile } = require('appbot-compiler'); const result = compile({ dir: './app', target: 'mobile', width: 320 }); console.log(result.bundle);
Debug
Known issues
breakingPackage is experimental and may have breaking changes between minor versions.
fix
Pin to exact version; no SemVer guarantees.
affects: >=0.0.0
deprecatedNo updates since 2014; considered abandoned.
fix
Migrate to a maintained modular compilation solution.
affects: all
gotchaCompiler only works with synchronous require-based CommonJS modules.
fix
Ensure all modules use synchronous require; no dynamic imports.
affects: all
Errors
Common errors & fixes
Cannot find module 'appbot-compiler'
Package not installed or not in node_modules.
fix
Run `npm install appbot-compiler --save-dev`.
compile is not a function
Import style mismatch (tried default import instead of named).
fix
Use `const { compile } = require('appbot-compiler');`.
Upgrade
Version history
0.0.19latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
13 hits · last 30 days
node
10
OpenAI (training)
1
Resources