{"id":25466,"library":"esbuild-xyaml-plugin","title":"esbuild-xyaml-plugin","description":"An esbuild plugin for loading and transforming XYAML files. Version 0.0.7 is the current stable release. This plugin allows importing XYAML files directly into JavaScript/TypeScript bundles built with esbuild. It integrates with esbuild's build pipeline, converting XYAML content to JavaScript objects or strings. As a community-maintained plugin, it fills a niche for projects using XYAML as a data format. Compared to generic YAML loaders, it is purpose-built for the XYAML schema. Release cadence is irregular. The plugin is distributed as a CommonJS module and requires esbuild as a peer dependency.","status":"active","version":"0.0.7","language":"javascript","source_language":"en","source_url":"https://github.com/teniryte/esbuild-xyaml-plugin","tags":["javascript"],"install":[{"cmd":"npm install esbuild-xyaml-plugin","lang":"bash","label":"npm"},{"cmd":"yarn add esbuild-xyaml-plugin","lang":"bash","label":"yarn"},{"cmd":"pnpm add esbuild-xyaml-plugin","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Peer dependency required to integrate as a plugin.","package":"esbuild","optional":false}],"imports":[{"note":"The package is CommonJS only; ESM import will fail unless using a bundler that interops.","wrong":"import xyamlPlugin from 'esbuild-xyaml-plugin';","symbol":"default","correct":"const xyamlPlugin = require('esbuild-xyaml-plugin');"},{"note":"When using a bundler or TypeScript with esModuleInterop, named default import works.","symbol":"default","correct":"import xyamlPlugin from 'esbuild-xyaml-plugin';"}],"quickstart":{"code":"const esbuild = require('esbuild');\nconst xyamlPlugin = require('esbuild-xyaml-plugin');\n\nesbuild.build({\n  entryPoints: ['./src/index.js'],\n  bundle: true,\n  outfile: './dist/app/app.js',\n  loader: {\n    '.js': 'jsx',\n  },\n  sourcemap: true,\n  target: ['chrome58', 'firefox57', 'safari11', 'edge16'],\n  define: {\n    'process.env.NODE_ENV': '\"development\"',\n  },\n  plugins: [xyamlPlugin()],\n}).catch(() => process.exit(1));","lang":"javascript","description":"Shows how to use the plugin with esbuild's build API, including loader configuration and plugin registration."},"warnings":[{"fix":"Call the imported default export: xyamlPlugin()","message":"The plugin must be invoked as a function (e.g., xyamlPlugin()) to create the plugin object, not passed as a reference.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Use require() or configure your bundler to handle CJS interop.","message":"The package is CommonJS only; using ESM import without bundler support may fail.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"None.","message":"No breaking changes reported for this version.","severity":"breaking","affected_versions":">=0.0.7"}],"env_vars":null,"search_vec":"'0.0.7':15 'allow':23 'build':39 'built':31,76 'bundl':30 'cadenc':82 'commonj':91 'communiti':52 'community-maintain':51 'compar':67 'content':43 'convert':41 'current':18 'data':65 'depend':99 'direct':27 'distribut':88 'esbuild':2,6,33,37,95 'esbuild-xyaml-plugin':1 'file':13,26 'fill':56 'format':66 'generic':69 'import':24 'integr':35 'irregular':84 'javascript':45,100 'javascript/typescript':29 'load':9 'loader':71 'maintain':53 'modul':92 'nich':58 'object':46 'peer':98 'pipelin':40 'plugin':4,7,22,54,86 'project':60 'purpos':75 'purpose-built':74 'releas':20,81 'requir':94 'schema':80 'stabl':19 'string':48 'transform':11 'use':61 'version':14 'xyaml':3,12,25,42,62,79 'yaml':70","created_at":"2026-05-01T13:44:54.740773+00:00","updated_at":"2026-05-01T13:44:54.740773+00:00","problems":[{"fix":"Ensure you import the module correctly and invoke it: const xyamlPlugin = require('esbuild-xyaml-plugin'); ... plugins: [xyamlPlugin()]","cause":"Importing the default export incorrectly or forgetting to call the plugin factory.","error":"TypeError: xyamlPlugin is not a function"},{"fix":"Install esbuild: npm install --save-dev esbuild","cause":"esbuild is not installed.","error":"Error: Cannot find module 'esbuild'"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":"","cli_version":null,"type":"library","homepage":null,"github":"https://github.com/teniryte/esbuild-xyaml-plugin","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/esbuild-xyaml-plugin","openapi_spec":null,"status_page":null,"smithery":null,"categories":["serialization"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-05-01","next_check":"2026-07-30","install_tag":null}}