{"id":17922555,"url":"https://github.com/rreverser/grunt-pure-cjs","last_synced_at":"2025-06-27T01:34:53.990Z","repository":{"id":12371183,"uuid":"15022253","full_name":"RReverser/grunt-pure-cjs","owner":"RReverser","description":"Grunt plugin for Pure CommonJS builder","archived":false,"fork":false,"pushed_at":"2016-02-21T06:11:26.000Z","size":208,"stargazers_count":2,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-14T11:47:19.009Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://npmjs.org/package/grunt-pure-cjs","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RReverser.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-MIT","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-12-08T11:10:26.000Z","updated_at":"2015-01-03T15:37:30.000Z","dependencies_parsed_at":"2022-09-01T23:31:24.121Z","dependency_job_id":null,"html_url":"https://github.com/RReverser/grunt-pure-cjs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RReverser%2Fgrunt-pure-cjs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RReverser%2Fgrunt-pure-cjs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RReverser%2Fgrunt-pure-cjs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RReverser%2Fgrunt-pure-cjs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RReverser","download_url":"https://codeload.github.com/RReverser/grunt-pure-cjs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246989750,"owners_count":20865331,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-28T20:39:44.493Z","updated_at":"2025-04-03T11:14:17.216Z","avatar_url":"https://github.com/RReverser.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# grunt-pure-cjs\n\n\u003e Grunt plugin for [Pure CommonJS builder](https://github.com/RReverser/pure-cjs)\n\n## Getting Started\nThis plugin requires Grunt `~0.4.2`\n\nIf you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:\n\n```shell\nnpm install grunt-pure-cjs --save-dev\n```\n\nOnce the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:\n\n```js\ngrunt.loadNpmTasks('grunt-pure-cjs');\n```\n\n## The \"pure_cjs\" task\n\n### Options\n\n* **map**: `String|Function(input, output)|Boolean` \u0026mdash; source map file; optional, doesn't generate source map by default; if `true` is provided, path default to `function (input, output) { return output + '.map' }`.\n* **exports**: `String|Function(input, output)` \u0026mdash; Exports top module with [UMD](https://github.com/umdjs/umd) with given global object name; optional, doesn't wrap into UMD by default.\n* **transform**: `Array|Function(input)` \u0026mdash; Array of or single function that returns transformation [through](https://github.com/dominictarr/through)-stream(s) to be used against input files before their usage; optional.\n* *See [Pure CommonJS builder](https://github.com/RReverser/pure-cjs) for other options.*\n\nIf set, built module will be wrapped into anonymous function and exports from top (input) module will be placed into provided value.\n\n### Usage Example\n\n```js\ngrunt.initConfig({\n  pure_cjs: {\n    options: {\n      exports: 'SuperLib'\n    },\n    files: {\n      'built/superLib.js': 'src/topModule.js'\n    },\n  },\n});\n```\n\n## Contributing\nIn lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [Grunt](http://gruntjs.com/).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frreverser%2Fgrunt-pure-cjs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frreverser%2Fgrunt-pure-cjs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frreverser%2Fgrunt-pure-cjs/lists"}