Registry / devops / tiny-webpack

tiny-webpack

JSON →
library0.0.1-alpha.1jsnpmunverified

A JavaScript bundler mimicking Webpack's core features including loader/plugin systems, code splitting, tree shaking, dynamic imports, and multi-page application support. Currently at version 0.0.1-alpha.1 (pre-release) with no stable release. Designed as a lightweight alternative for learning or simple projects, but lacks production readiness. Differentiators include a simplified API and Webpack-compatible configuration, but it is not suitable for production use.

npm install tiny-webpack
INSTALL
IMPORT
SIG · TINY-WEBPACK
T
tiny-webpack
devopsjavascriptv0.0.1-alpha.1
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.

jspack
import { jspack } from 'tiny-webpack'
const jspack = require('tiny-webpack')
The only named export; ESM-only (no CJS wrapper)
default export
import jspack from 'tiny-webpack'
module.exports = require('tiny-webpack')
No default export; must use named import { jspack }
types
import type { JspackOptions } from 'tiny-webpack'
import { JspackOptions } from 'tiny-webpack'
TypeScript types bundled; use type import for options interfaces

Basic usage of tiny-webpack: configuration and programmatic build.

// jspack.config.js export default { entry: './src/index.js', output: { path: process.cwd() + '/dist', filename: 'bundle.js' }, mode: 'development' }; // build.js import { jspack } from 'tiny-webpack'; import config from './jspack.config.js'; const compiler = jspack(config); compiler.run((err, stats) => { if (err) { console.error(err); return; } console.log(stats.toJson()); });
tiny-webpack --version
Debug
Known issues
breakingAlpha version – no stable API; exports may change without notice.
fix
Do not use in production; pin exact version and expect breaking changes.
affects: 0.0.1-alpha.x
gotchaUses ESM only; CommonJS require() will fail.
fix
Use ESM imports or upgrade Node.js to support ESM.
affects: *
gotchaNo default export; must import { jspack }.
fix
Use named import syntax.
affects: *
gotchaNo pre-built plugins; must implement custom loaders/plugins from scratch.
fix
Write your own plugins or use Webpack for plugin ecosystem.
affects: *
deprecatedresolveLoader.modules is not officially supported; may be removed.
fix
Use standard node_modules resolution.
affects: >=0.0.1-alpha.1
Errors
Common errors & fixes
Error [ERR_REQUIRE_ESM]: require() of ES Module not supported.
tiny-webpack is ESM-only; using CommonJS require() fails.
fix
Use import { jspack } from 'tiny-webpack' or set type: 'module' in package.json.
TypeError: jspack is not a function
Attempted to import default export which does not exist.
fix
Use import { jspack } from 'tiny-webpack' instead of import jspack from 'tiny-webpack'.
Module not found: Can't resolve 'style-loader'
Required loaders are not included with tiny-webpack; must be installed separately.
fix
npm install style-loader less-loader --save-dev
Upgrade
Version history
0.0.1-alpha.1latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
tiny-webpack — npm install tiny-webpack · libregistry