{"id":27953,"library":"meteor-client-bundler","title":"Meteor Client Bundler","description":"A CLI tool and module bundler that combines Meteor Atmosphere packages into a single JavaScript module for use outside of the full Meteor platform. Version 0.6.0 is the latest stable release (last release in 2018). It uses the Meteor command-line tool to resolve and bundle packages, producing a standalone file that provides Meteor's client-side API (including DDP). Key differentiator: it enables frameworks like Angular CLI, React Native, or Ionic to use Meteor's real-time data features without running a Meteor server. Compared to alternatives like `ddp-client`, this bundles full Meteor client runtime including accounts and file upload packages.","status":"maintenance","version":"0.6.0","language":"javascript","source_language":"en","source_url":"https://github.com/Urigo/meteor-client-bundler","tags":["javascript","meteor","client"],"install":[{"cmd":"npm install meteor-client-bundler","lang":"bash","label":"npm"},{"cmd":"yarn add meteor-client-bundler","lang":"bash","label":"yarn"},{"cmd":"pnpm add meteor-client-bundler","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Requires the Meteor CLI tool to be installed globally for bundling packages","package":"meteor","optional":false},{"reason":"Configuration file in the project root for bundler options","package":"meteor-client.config.json","optional":true}],"imports":[{"note":"The bundled module exports Meteor as a named export, not a default export.","wrong":"import Meteor from 'meteor-client'","symbol":"Meteor","correct":"import { Meteor } from 'meteor-client'"},{"note":"Available only if accounts-base is included in the bundle.","wrong":"const Accounts = require('meteor-client').Accounts","symbol":"Accounts","correct":"import { Accounts } from 'meteor-client'"},{"note":"Also exports other Meteor globals like Random, EJSON, etc.","wrong":"","symbol":"Mongo","correct":"import { Mongo } from 'meteor-client'"},{"note":"CommonJS usage – destructure named exports from the required object.","wrong":"const meteor = require('meteor-client'); // returns an object, not a function","symbol":"require('meteor-client')","correct":"const MeteorClient = require('meteor-client'); const { Meteor } = MeteorClient;"}],"quickstart":{"code":"// Install meteor-client globally\nnpm install -g meteor-client-bundler\n\n# Create a config file meteor-client.config.json\n{\n  \"release\": \"1.9\",\n  \"runtime\": {\n    \"DDP_DEFAULT_CONNECTION_URL\": \"http://localhost:3000\"\n  },\n  \"import\": [\"meteor-base\"]\n}\n\n# Run bundler\nmeteor-client bundle --destination meteor-bundle.js\n\n# In your app\nimport { Meteor } from './meteor-bundle';\nMeteor.connect('http://localhost:3000');\nMeteor.call('myMethod', (err, res) => {\n  if (err) console.error(err);\n  else console.log(res);\n});\n","lang":"typescript","description":"Shows installation, configuration, bundling with meteor-client-bundler, and client usage with Meteor.connect and Meteor.call."},"warnings":[{"fix":"Change `import Meteor from 'meteor-client'` to `import { Meteor } from 'meteor-client'`","message":"The module exports have changed in v0.6.0: Meteor is now an ES module named export, not a default export.","severity":"breaking","affected_versions":">=0.6.0"},{"fix":"Install Meteor: `curl https://install.meteor.com/ | sh`","message":"The bundler requires the Meteor CLI tool to be installed globally; without it, `meteor-client bundle` will fail.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Use `\"runtime\": { \"DDP_DEFAULT_CONNECTION_URL\": \"...\" }` in the config file","message":"The `--url` command-line option is deprecated in favor of the `runtime.DDP_DEFAULT_CONNECTION_URL` config field.","severity":"deprecated","affected_versions":">=0.0.0"},{"fix":"Use a bundler like webpack or rollup to transform the output, or set the output to CommonJS via the config (not documented).","message":"The bundled module does not work in browser environments that do not support ES modules natively.","severity":"gotcha","affected_versions":">=0.6.0"}],"env_vars":null,"last_verified":"2026-05-09T00:00:00.000Z","next_check":"2026-08-07T00:00:00.000Z","problems":[{"fix":"Ensure you have run `meteor-client bundle` and the output file path matches your import. For example, if bundled to `meteor-bundle.js`, import from './meteor-bundle'.","cause":"The module is not installed or the import path is incorrect.","error":"Error: Can't resolve 'meteor-client'"},{"fix":"Call `import { Meteor } from 'meteor-client'; Meteor.connect('...');` and ensure the connection URL is reachable.","cause":"Using the module before calling Meteor.connect or not importing correctly.","error":"Meteor is not defined"},{"fix":"Check the `release` field in config; ensure Meteor is installed and the release exists. Use `meteor update` to fetch releases.","cause":"The specified Meteor release does not include the required packages or the release is not installed.","error":"Error: The package 'meteor-base' was not found in the Meteor universe"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}