{"id":26782,"library":"babel-plugin-twine","title":"babel-plugin-twine","description":"Babel plugin for transpiling Twine markup (interactive fiction/storytelling format) into React components. Version 1.0.1. This plugin integrates with Babel to process .twine or custom twine files in your build pipeline, emitting JSX. No other babel twine plugins exist; it is experimental with minimal documentation. Not actively maintained; last update unknown.","status":"deprecated","version":"1.0.1","language":"javascript","source_language":"en","source_url":null,"tags":["javascript","twine","text-based","babel","transpiler"],"install":[{"cmd":"npm install babel-plugin-twine","lang":"bash","label":"npm"},{"cmd":"yarn add babel-plugin-twine","lang":"bash","label":"yarn"},{"cmd":"pnpm add babel-plugin-twine","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"Package lacks type definitions; likely CommonJS but ES import may work depending on bundler. Use require for safety.","wrong":"const twinePlugin = require('babel-plugin-twine')","symbol":"default","correct":"import twinePlugin from 'babel-plugin-twine'"},{"note":"Babel resolves plugin names without the babel-plugin- prefix.","wrong":"module.exports = { plugins: ['babel-plugin-twine'] }","symbol":"babel config usage","correct":"module.exports = { plugins: ['twine'] }"},{"note":"Options must be in an array: ['plugin', options].","wrong":"module.exports = { plugins: ['twine', { option: true }] }","symbol":"with custom options","correct":"module.exports = { plugins: [['twine', { option: true }]] }"}],"quickstart":{"code":"// Install: npm install babel-plugin-twine --save-dev\n// In your babel config (e.g., babel.config.js):\nmodule.exports = {\n  plugins: ['twine']\n};\n\n// Then in your code, import a twine file (assuming custom loader or webpack):\nimport story from './story.twine';\n// The plugin transforms the twine markup into React components.\n// Note: This example assumes a custom loader; twine files are not standard JS.","lang":"javascript","description":"Shows how to install and configure the babel plugin in a Babel config file."},"warnings":[{"fix":"Consider forking or using an alternative like t3js or custom twine parser.","message":"Package is archived or unmaintained; no updates since initial release.","severity":"deprecated","affected_versions":">=1.0.0"},{"fix":"Check peer dependencies; likely works with Babel 6 only.","message":"Requires specific Babel version compatibility; may break with Babel 7+.","severity":"breaking","affected_versions":">=1.0.0"},{"fix":"Create a custom webpack loader for .twine files.","message":"No TypeScript definitions or webpack loader included; integration requires manual setup.","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run npm install babel-plugin-twine --save-dev or check package.json.","cause":"Package not installed correctly or missing from node_modules.","error":"Module not found: Can't resolve 'babel-plugin-twine'"},{"fix":"Ensure npm install completed. Use 'twine' (without babel-plugin- prefix) in plugins array.","cause":"Babel cannot locate the plugin; it's not in node_modules or name mismatch.","error":"Error: Cannot find module 'babel-plugin-twine' from '/path/to/project'"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}