{"name":"@swc-node/core","version":"1.4.0","keywords":["swc","babel","esbuild","rust","n-api","napi","node-rs","uglify","napi-rs","terser","webpack","ts-node","typescript","tsc"],"author":{"name":"LongYinan","email":"lynweklm@gmail.com"},"license":"MIT","_id":"@swc-node/core@1.4.0","homepage":"https://github.com/Brooooooklyn/swc-node","bugs":{"url":"https://github.com/Brooooooklyn/swc-node/issues"},"dist":{"shasum":"5ee1c069c6be436a526430eec95954ce49d3af12","tarball":"http://registry-npm.ywwl.com/@swc-node/core/download/@swc-node/core-1.4.0.tgz","fileCount":7,"integrity":"sha512-KFCcbjAIEVUZ9QcRORSABq3vsRTkSHldbpBdOQZwCgjn9I0zeT280+kpdudO4H4cT80TqR+BQEmnIO3OalmYOw==","signatures":[{"sig":"MEUCICr7OFKnAeRnqa/DxYYlTqdDHGADuO9x0VihdWrovx7OAiEAmd7kFOoN892LctvZiRc7KfDUP2z4nyznn7FXAFdDMbo=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":16049,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgiYOiCRA9TVsSAnZWagAAMiIP/3qLfn0bfGyVRgxi57jY\ndpl5nCt0GTIyZCoRCvZobXGEJ4p2tXH+OBkkrjK9GCxSOWilhZ7uTEB/2aXc\na7hZx5UiTUKlxNkMlXF4esy2yuJdFdHPhw40xOLSm7fDXrGcpphR+PqgPppG\nir7oYx9FeuuFbTqG3RNmJ4VN2/kqx8kceYJll9rUlJgaHLo1yvFAfUI28Brk\noP2Fl0woLtGKJamOseJjUYaD3QWlsPMm6BjMKh3QgTXjDMjEdt2gIH+MgPbY\n7i/auOfWldDl/Dd9tGt7H+7ki4sRdVj0sE8GQl8CZoIJp7TnOw1PvQ7KvtpQ\n2Qx6ZZlXqgirEOH8Q53RhIvvSDYR7CRW/r4p58XVYvEeWo2iccYGesotyb6M\nyjlsJcN0uYKXxeRJY8f/9BSCoHqFCBY5Sgk9V1I4nECGnYBpSBwUujP9LySL\n/BgiNKaMX3Y9IMx1Wpkd/kzv43wcIk3zmkQw2TlQiVSiPTwEIeRoVGCvY7mo\nLtNzufwLLo7lDyXE2JlAvgtLKyegK/j0FPpcXR8j15AILmWyKYn3hYVvbAYv\nzuxNtUDZG/fo6fOBwwsUwDewgStHRPAELTygC3ADVGDJLekTC6rxFNK3noRT\nlkEwLFumQ3AOUmJgGX/88VJIGP/g4brspmPvFWlwfL+WDDPdc/6BNdXFgufk\nOUPR\r\n=2p1a\r\n-----END PGP SIGNATURE-----\r\n","size":5212,"noattachment":false,"key":"/@swc-node/core/-/@swc-node/core-1.4.0.tgz"},"main":"lib/index.js","engines":{"node":">= 10"},"funding":{"url":"https://github.com/sponsors/Brooooooklyn","type":"github"},"gitHead":"2737279e210f0104cb7094a6c0906a1bb6f4c3df","typings":"lib/index.d.ts","_npmUser":{"name":"broooooklyn","email":"lynweklm@gmail.com"},"repository":{"url":"git+https://github.com/Brooooooklyn/swc-node.git","type":"git"},"_npmVersion":"lerna/4.0.0/node@v14.16.1+x64 (linux)","description":"Faster swc nodejs binding","directories":{},"_nodeVersion":"14.16.1","dependencies":{"@swc/core":"^1.2.54"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/core_1.4.0_1619624866314_0.12893758267802813","host":"s3://npm-registry-packages"},"readme":"# `@swc-node/core`\n\n<a href=\"https://npmcharts.com/compare/@swc-node/core?minimal=true\"><img src=\"https://img.shields.io/npm/dm/@swc-node/core.svg?sanitize=true\" alt=\"Downloads\" /></a>\n\n> 🚀 Help me to become a full-time open-source developer by [sponsoring me on Github](https://github.com/sponsors/Brooooooklyn)\n\n## Benchmark\n\n> transform AjaxObservable.ts to ES2015 & CommonJS `JavaScript`.\n\n```\n@swc-node/core x 151 ops/sec ±3.74% (77 runs sampled)\n@swc/core x 107 ops/sec ±0.51% (78 runs sampled)\nesbuild x 52.89 ops/sec ±1.58% (67 runs sampled)\ntypescript x 21.08 ops/sec ±9.68% (40 runs sampled)\nTransform rxjs/AjaxObservable.ts benchmark bench suite: Fastest is @swc-node/core\n```\n\n## Usage\n\n```ts\nexport interface Options {\n  target?: 'es3' | 'es5' | 'es2015' | 'es2016' | 'es2017' | 'es2018' | 'es2019' | 'es2020'\n  module?: 'commonjs' | 'umd' | 'amd' | 'es6'\n  sourcemap?: boolean | 'inline'\n  experimentalDecorators?: boolean\n  emitDecoratorMetadata?: boolean\n  dynamicImport?: boolean\n  esModuleInterop?: boolean\n  keepClassNames?: boolean\n  react?: Partial<ReactConfig>\n  paths?: {\n    [from: string]: [string]\n  }\n}\n\nexport interface ReactConfig {\n  /**\n   * Replace the function used when compiling JSX expressions.\n   *\n   * Defaults to `React.createElement`.\n   */\n  pragma: string\n  /**\n   * Replace the component used when compiling JSX fragments.\n   *\n   * Defaults to `React.Fragment`\n   */\n  pragmaFrag: string\n  /**\n   * Toggles whether or not to throw an error if a XML namespaced tag name is used. For example:\n   * `<f:image />`\n   *\n   * Though the JSX spec allows this, it is disabled by default since React's\n   * JSX does not currently have support for it.\n   *\n   */\n  throwIfNamespace: boolean\n  /**\n   * Toggles plugins that aid in development, such as @swc/plugin-transform-react-jsx-self\n   * and @swc/plugin-transform-react-jsx-source.\n   *\n   * Defaults to `false`,\n   *\n   */\n  development: boolean\n  /**\n   * Use `Object.assign()` instead of `_extends`. Defaults to false.\n   */\n  useBuiltins: boolean\n}\n\nexport function transformSync(\n  source: string | Buffer,\n  path: string,\n  options?: Options,\n): {\n  code: string\n  map: string\n}\n\nexport function transform(\n  source: string | Buffer,\n  path: string,\n  options?: Options,\n): Promise<{\n  code: string\n  map: string\n}>\n```\n","publish_time":1619624866436,"maintainers":[{"name":"broooooklyn","email":"lynweklm@gmail.com"}],"_cnpm_publish_time":1619624866436,"dist-tags":{"latest":"1.15.0"}}