{"_id":"@putout/plugin-group-imports-by-source","_rev":"4159935","name":"@putout/plugin-group-imports-by-source","description":"🐊Putout plugin adds ability to find and group imports by source","dist-tags":{"latest":"2.0.4"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"time":{"modified":"2026-03-01T20:36:53.000Z","created":"2024-06-18T20:28:41.651Z","2.0.4":"2024-12-22T11:09:49.632Z","2.0.3":"2024-12-22T11:06:09.574Z","2.0.2":"2024-12-22T11:03:10.194Z","2.0.1":"2024-12-21T20:39:06.263Z","2.0.0":"2024-10-18T11:21:44.843Z","1.0.0":"2024-06-18T20:28:41.651Z"},"users":{},"author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"repository":{"type":"git","url":"git+https://github.com/coderaiser/putout.git"},"versions":{"2.0.4":{"name":"@putout/plugin-group-imports-by-source","version":"2.0.4","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"🐊Putout plugin adds ability to find and group imports by source","homepage":"https://github.com/coderaiser/putout/tree/v36.18.0/packages/plugin-group-imports-by-source#readme","main":"lib/group-imports-by-source.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git+https://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","watch:test":"madrun watch:test","lint":"madrun lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","fix:lint":"madrun fix:lint","coverage":"madrun coverage","report":"madrun report"},"dependencies":{},"keywords":["putout","putout-plugin","putout-plugin-remove","plugin","debugger"],"devDependencies":{"@putout/plugin-nodejs":"*","@putout/test":"^11.0.0","c8":"^10.0.0","eslint":"^9.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^23.0.0","lerna":"^6.0.1","madrun":"^10.0.0","nodemon":"^3.0.1"},"peerDependencies":{"putout":">=36"},"license":"MIT","engines":{"node":">=18"},"publishConfig":{"access":"public"},"_id":"@putout/plugin-group-imports-by-source@2.0.4","gitHead":"06fa9243858a31e21523413915cb274b43652622","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_nodeVersion":"22.12.0","_npmVersion":"10.9.0","dist":{"shasum":"9ed0326c821d1f6ee5dbabd8076b14b28b5e4b9f","size":2659,"noattachment":false,"key":"/@putout/plugin-group-imports-by-source/-/@putout/plugin-group-imports-by-source-2.0.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/@putout/plugin-group-imports-by-source/download/@putout/plugin-group-imports-by-source-2.0.4.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/plugin-group-imports-by-source_2.0.4_1734865789445_0.35791152156851314"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-12-22T11:09:49.632Z","publish_time":1734865789632,"_source_registry_name":"default","_cnpm_publish_time":1734865789632},"2.0.3":{"name":"@putout/plugin-group-imports-by-source","version":"2.0.3","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"🐊Putout plugin adds ability to find and group imports by source","homepage":"https://github.com/coderaiser/putout/tree/v36.18.0/packages/plugin-group-imports-by-source#readme","main":"lib/group-imports-by-source.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git+https://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","watch:test":"madrun watch:test","lint":"madrun lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","fix:lint":"madrun fix:lint","coverage":"madrun coverage","report":"madrun report"},"dependencies":{},"keywords":["putout","putout-plugin","putout-plugin-remove","plugin","debugger"],"devDependencies":{"@putout/plugin-nodejs":"*","@putout/test":"^11.0.0","c8":"^10.0.0","eslint":"^9.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^23.0.0","lerna":"^6.0.1","madrun":"^10.0.0","nodemon":"^3.0.1"},"peerDependencies":{"putout":">=36"},"license":"MIT","engines":{"node":">=18"},"publishConfig":{"access":"public"},"_id":"@putout/plugin-group-imports-by-source@2.0.3","gitHead":"06fa9243858a31e21523413915cb274b43652622","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_nodeVersion":"22.12.0","_npmVersion":"10.9.0","dist":{"shasum":"b5e1f3e13962c8d32e516c1d213c65a5d87bfc43","size":2622,"noattachment":false,"key":"/@putout/plugin-group-imports-by-source/-/@putout/plugin-group-imports-by-source-2.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/@putout/plugin-group-imports-by-source/download/@putout/plugin-group-imports-by-source-2.0.3.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/plugin-group-imports-by-source_2.0.3_1734865569351_0.5039536643172724"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-12-22T11:06:09.574Z","publish_time":1734865569574,"_source_registry_name":"default","_cnpm_publish_time":1734865569574},"2.0.2":{"name":"@putout/plugin-group-imports-by-source","version":"2.0.2","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"🐊Putout plugin adds ability to find and group imports by source","homepage":"https://github.com/coderaiser/putout/tree/v36.18.0/packages/plugin-group-imports-by-source#readme","main":"lib/group-imports-by-source.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git+https://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","watch:test":"madrun watch:test","lint":"madrun lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","fix:lint":"madrun fix:lint","coverage":"madrun coverage","report":"madrun report"},"dependencies":{},"keywords":["putout","putout-plugin","putout-plugin-remove","plugin","debugger"],"devDependencies":{"@putout/plugin-nodejs":"*","@putout/test":"^11.0.0","c8":"^10.0.0","eslint":"^9.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^23.0.0","lerna":"^6.0.1","madrun":"^10.0.0","nodemon":"^3.0.1"},"peerDependencies":{"putout":">=36"},"license":"MIT","engines":{"node":">=18"},"publishConfig":{"access":"public"},"_id":"@putout/plugin-group-imports-by-source@2.0.2","gitHead":"06fa9243858a31e21523413915cb274b43652622","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_nodeVersion":"22.12.0","_npmVersion":"10.9.0","dist":{"shasum":"58eaaf6d980e68d30b85944d81356a5937fee707","size":2616,"noattachment":false,"key":"/@putout/plugin-group-imports-by-source/-/@putout/plugin-group-imports-by-source-2.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/@putout/plugin-group-imports-by-source/download/@putout/plugin-group-imports-by-source-2.0.2.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/plugin-group-imports-by-source_2.0.2_1734865390005_0.33252451320327125"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-12-22T11:03:10.194Z","publish_time":1734865390194,"_source_registry_name":"default","_cnpm_publish_time":1734865390194},"2.0.1":{"name":"@putout/plugin-group-imports-by-source","version":"2.0.1","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"🐊Putout plugin adds ability to find and group imports by source","homepage":"https://github.com/coderaiser/putout/tree/master/packages/plugin-group-imports-by-source#readme","main":"lib/group-imports-by-source.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git+https://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","watch:test":"madrun watch:test","lint":"madrun lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","fix:lint":"madrun fix:lint","coverage":"madrun coverage","report":"madrun report"},"dependencies":{},"keywords":["putout","putout-plugin","putout-plugin-remove","plugin","debugger"],"devDependencies":{"@putout/plugin-nodejs":"*","@putout/test":"^11.0.0","c8":"^10.0.0","eslint":"^9.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^23.0.0","lerna":"^6.0.1","madrun":"^10.0.0","nodemon":"^3.0.1"},"peerDependencies":{"putout":">=36"},"license":"MIT","engines":{"node":">=18"},"publishConfig":{"access":"public"},"_id":"@putout/plugin-group-imports-by-source@2.0.1","gitHead":"abde958138e302f0560ff37ab0d586d81ffc5305","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_nodeVersion":"22.12.0","_npmVersion":"10.9.0","dist":{"shasum":"eb9661236035e1dab1fdbd3d881a65cbf2fe8c4e","size":2610,"noattachment":false,"key":"/@putout/plugin-group-imports-by-source/-/@putout/plugin-group-imports-by-source-2.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/@putout/plugin-group-imports-by-source/download/@putout/plugin-group-imports-by-source-2.0.1.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/plugin-group-imports-by-source_2.0.1_1734813546081_0.6543461331591403"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-12-21T20:39:06.263Z","publish_time":1734813546263,"_source_registry_name":"default","_cnpm_publish_time":1734813546263},"2.0.0":{"name":"@putout/plugin-group-imports-by-source","version":"2.0.0","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"🐊Putout plugin adds ability to find and group imports by source","homepage":"https://github.com/coderaiser/putout/tree/master/packages/plugin-group-imports-by-source#readme","main":"lib/group-imports-by-source.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git+https://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","watch:test":"madrun watch:test","lint":"madrun lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","fix:lint":"madrun fix:lint","coverage":"madrun coverage","report":"madrun report"},"dependencies":{},"keywords":["putout","putout-plugin","putout-plugin-remove","plugin","debugger"],"devDependencies":{"@putout/plugin-nodejs":"*","@putout/test":"^11.0.0","c8":"^10.0.0","eslint":"^9.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^23.0.0","lerna":"^6.0.1","madrun":"^10.0.0","nodemon":"^3.0.1"},"peerDependencies":{"putout":">=36"},"license":"MIT","engines":{"node":">=18"},"publishConfig":{"access":"public"},"_id":"@putout/plugin-group-imports-by-source@2.0.0","gitHead":"c360fefbfd7873f0523d679a515ac73150976ac1","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_nodeVersion":"22.8.0","_npmVersion":"10.8.2","dist":{"shasum":"082c278c3b9a28a5222a9e388afc6286e2b21d26","size":2578,"noattachment":false,"key":"/@putout/plugin-group-imports-by-source/-/@putout/plugin-group-imports-by-source-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/@putout/plugin-group-imports-by-source/download/@putout/plugin-group-imports-by-source-2.0.0.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/plugin-group-imports-by-source_2.0.0_1729250504673_0.4770502777049699"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-10-18T11:21:44.843Z","publish_time":1729250504843,"_source_registry_name":"default","_cnpm_publish_time":1729250504843},"1.0.0":{"name":"@putout/plugin-group-imports-by-source","version":"1.0.0","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"🐊Putout plugin adds ability to find and group imports by source","homepage":"https://github.com/coderaiser/putout/tree/master/packages/plugin-group-imports-by-source#readme","main":"lib/group-imports-by-source.js","release":false,"tag":false,"changelog":false,"repository":{"type":"git","url":"git://github.com/coderaiser/putout.git"},"scripts":{"test":"madrun test","watch:test":"madrun watch:test","lint":"madrun lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","fix:lint":"madrun fix:lint","coverage":"madrun coverage","report":"madrun report"},"dependencies":{},"keywords":["putout","putout-plugin","putout-plugin-remove","plugin","debugger"],"devDependencies":{"@putout/plugin-nodejs":"^11.11.0","@putout/test":"^10.0.0","c8":"^10.0.0","eslint":"^9.0.0","eslint-plugin-n":"^17.0.0","eslint-plugin-putout":"^22.0.0","lerna":"^6.0.1","madrun":"^10.0.0","nodemon":"^3.0.1"},"peerDependencies":{"putout":">=35"},"license":"MIT","engines":{"node":">=18"},"publishConfig":{"access":"public"},"_id":"@putout/plugin-group-imports-by-source@1.0.0","gitHead":"656ffedd0630cb11e40be65b95f540884b8ea669","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"_nodeVersion":"22.3.0","_npmVersion":"10.8.1","dist":{"shasum":"cbd39c0ebdacaa54027bdaf52a57b8e62f2fed3f","size":2581,"noattachment":false,"key":"/@putout/plugin-group-imports-by-source/-/@putout/plugin-group-imports-by-source-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/@putout/plugin-group-imports-by-source/download/@putout/plugin-group-imports-by-source-1.0.0.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/plugin-group-imports-by-source_1.0.0_1718742521521_0.6191527212766852"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-06-18T20:28:41.651Z","publish_time":1718742521651,"_source_registry_name":"default","_cnpm_publish_time":1718742521651}},"readme":"# @putout/plugin-group-imports-by-source [![NPM version][NPMIMGURL]][NPMURL]\n\n[NPMIMGURL]: https://img.shields.io/npm/v/@putout/plugin-group-imports-by-source.svg?style=flat&longCache=true\n[NPMURL]: https://npmjs.org/package/@putout/plugin-group-imports-by-source \"npm\"\n\n> The static **import** declaration is used to import read-only live bindings which are exported by another module.\n> The imported bindings are called live bindings because they are updated by the module that exported the binding, but cannot be re-assigned by the importing module.\n>\n> (c) [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import)\n\n????[**Putout**](https://github.com/coderaiser/putout) plugin adds ability to find and group `import` statements by source. Checkout in ????[**Putout Editor**](https://putout.cloudcmd.io/#/gist/3cc782acf95211f9d456d63a99032ee1/0674223d050bba572f5271ffdccf8616cb441af5). For **CommonJS** use [`nodejs/group-require-by-id`](https://www.npmjs.com/package/@putout/plugin-nodejs#group-require-by-id).\nMerged with [`@putout/plugin-esm`](https://www.npmjs.com/package/@putout/plugin-esm##group-imports-by-source).\n\nGroup order:\n\n- ✅ builtins;\n- ✅ external;\n- ✅ internal;\n\n## Install\n\n```\nnpm i @putout/plugin-group-imports-by-source\n```\n\n## Rule\n\n```json\n{\n    \"rules\": {\n        \"group-imports-by-source\": \"on\"\n    }\n}\n```\n\n## ❌ Example of incorrect code\n\n```js\nimport fs from 'node:fs';\nimport {lodash} from 'lodash';\nimport react from 'react';\nimport d from '../hello.js';\nimport ss from '../../bb/ss.js';\nimport b from './ss.js';\n\nconst c = 5;\n```\n\n## ✅ Example of correct code\n\n```js\nimport fs from 'node:fs';\nimport react from 'react';\nimport {lodash} from 'lodash';\nimport b from './ss.js';\nimport d from '../hello.js';\nimport ss from '../../bb/ss.js';\n\nconst c = 5;\n```\n\n## License\n\nMIT\n","_attachments":{},"homepage":"https://github.com/coderaiser/putout/tree/v36.18.0/packages/plugin-group-imports-by-source#readme","bugs":{"url":"https://github.com/coderaiser/putout/issues"},"license":"MIT"}