{"id":18609776,"url":"https://github.com/unlight/sublime-import-helper","last_synced_at":"2025-07-06T02:34:41.758Z","repository":{"id":13916352,"uuid":"68383775","full_name":"unlight/sublime-import-helper","owner":"unlight","description":"A Sublime Text Plugin that helps you to import your modules.","archived":false,"fork":false,"pushed_at":"2023-04-24T23:27:41.000Z","size":11771,"stargazers_count":69,"open_issues_count":10,"forks_count":7,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-25T05:41:36.544Z","etag":null,"topics":["sublime-package","sublime-plugin","sublime-text","sublime-text-plugin"],"latest_commit_sha":null,"homepage":"","language":"Python","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/unlight.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-09-16T13:50:52.000Z","updated_at":"2024-07-18T17:48:18.000Z","dependencies_parsed_at":"2022-08-07T07:15:56.845Z","dependency_job_id":null,"html_url":"https://github.com/unlight/sublime-import-helper","commit_stats":null,"previous_names":[],"tags_count":37,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fsublime-import-helper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fsublime-import-helper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fsublime-import-helper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Fsublime-import-helper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/unlight","download_url":"https://codeload.github.com/unlight/sublime-import-helper/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248309742,"owners_count":21082271,"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":["sublime-package","sublime-plugin","sublime-text","sublime-text-plugin"],"created_at":"2024-11-07T03:07:13.346Z","updated_at":"2025-04-10T22:31:39.828Z","avatar_url":"https://github.com/unlight.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sublime-import-helper\n\nA Sublime Text Plugin that helps you to import your modules.\n\n## Supported Languages\n\n-   TypeScript\n-   JavaScript (ES2015)\n\n## Requirements\n\n-   Node.JS 12.0+\n\n## Installation\n\n#### [PackageControl](https://packagecontrol.io/packages/ImportHelper)\n\n-   Select `Package Control: Install Package` from command palette\n-   Select `ImportHelper`\n\n#### Manual Installation\n\nYou can install `sublime-import-helper` manually using git by running the following command\nwithin sublime packages directory (Preferences \u003e Browse Packages):\n\n```\ngit clone https://github.com/unlight/sublime-import-helper ImportHelper\n```\n\n#### Install Old version\n\nCheck https://github.com/unlight/sublime-import-helper/releases page,\ndowload source code archive, unzip to `Data/Packages/ImportHelper`.\n\nOr you can use git, see like in manual installation:\n\n```sh\ngit clone https://github.com/unlight/sublime-import-helper ImportHelper\ncd ImportHelper\ngit checkout -f v2.3.2\n```\n\n## Usage\n\n#### Initialize / Setup / Update modules\n\n-   Restart plugin - update node_modules, source modules\n\n#### Insert import\n\n-   Set cursor or select word\n-   Press `ctrl+alt+i`, or select the command from command palette\n\n#### List imports\n\n-   Press `alt+i, alt+l`, or select the command from command palette\n\n#### Update source modules\n\n-   Press `alt+i, alt+s`, or select the command from command palette\n\n#### Import from clipboard\n\n-   Copy text to clipboard `ctrl+c`\n-   Press `alt+i, alt+k`, or select the command from command palette\n\n## Screenshots\n\n![](https://raw.githubusercontent.com/unlight/sublime-import-helper/master/screenshots/insert-import.gif)\n\n## Settings\n\nThere are some several configuration settings. Open plugin settings file by opening in menu:  \nPreferences -\u003e Package Settings -\u003e Import Helper  \nAlso, there are some optional project specific settings.  \nThe precedence of getting of value of setting is following:\n\n1. Project file\n2. Plugin file settings\n3. Default settings\n\n#### `from_quote`\n\nWhat kind of quotes will be used in import statement.\n\n-   Type: `string`\n-   Default: `'`\n\n#### `no_semicolon`\n\nRemove semicolon at the end of `import` string.\n\n-   Type: `boolean`\n-   Default: `false`\n\n#### `insert_space_in_braces`\n\nInsert space after opening and before closing non empty braces.\n\n-   Type: `boolean`\n-   Default: `true`\n\n#### `node_bin`\n\nSometimes sublime cannot find node executable, if it happens. Set `node_bin` explicitly (e.g. c:/nodejs/node.exe)\n\n-   Type: `string`\n-   Default: '' (auto detect)\n\n#### `import_path_mapping`\n\nHow to apply path mapping (read more about [Module Resolution and Path Mapping](http://www.typescriptlang.org/docs/handbook/module-resolution.html)).\n\nIf `enabled` implementation will try to find first matching alias.\n\n-   Type: `string`\n-   Enum: `['disabled', 'enabled']`\n-   Default: `enabled`\n\n#### `autocomplete_export_names`\n\nShow all possible export names from sources and node modules in autocomplete menu.\n\n-   Type: `boolean`\n-   Default: `true`\n\n#### `autocomplete_auto_import`\n\nAutomatically add import statement if export name was selected from autocomplete menu (Ctrl + Space).  \nRequires `autocomplete_export_names: true`.\n\n-   Type: `boolean`\n-   Default: `false`\n\n#### `remove_trailing_index`\n\nRemove index suffix ending in file path\n\n-   Type: `boolean`\n-   Default: `true`\n\n#### `import_root` (project file only)\n\nPath to your project root folder (not source folder). If not set,\ntries automatically detect. For single souce folder `folders[0].path` will be used,\nfor serveral source folders common path will be used.\n\n#### `import_file_extension`\n\nOption what to do with file extension in import statement.\n\n-   Type: `string`\n-   Default: `remove`\n\nOptions:\n\n-   **`remove`** js/ts/jsx/tsx extension will be removed\n-   **`js`** js/ts/jsx/tsx will be replaced to js\n-   **`as_is`** will stay as is\n\n#### Example of settings in project file:\n\nExample of project file:\n\n```\n{\n\t\"import_root\": \".\",\n\t\"from_quote\": \"'\",\n\t\"folders\": [\n\t\t{\n\t\t\t\"path\": \".\"\n\t\t}\n\t]\n}\n```\n\n## Notes for `No imports found for ...` message\n\nLooks like you do not have opened folders in current Sublime window.\n\nIt is recommended to create project from your working files and folders, you can do it in top menu:  \n`Project -\u003e Save project as...`  \nSave project file in any place you want.  \nThen restart Sublime.\n\nCurrently, it is not posssible to detect when project was switched (Project -\u003e Quick Switch Project),\nin this case you need manually re-initialize plugin:  \nSelect `Import Helper: Initialize / Setup / Update modules` from command palette\n\n## Dev Notes\n\n```python\nsublime.log_input(True); sublime.log_commands(True); sublime.log_result_regex(True)\nsublime.log_input(False); sublime.log_commands(False); sublime.log_result_regex(False)\npython3 -m black .\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funlight%2Fsublime-import-helper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Funlight%2Fsublime-import-helper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funlight%2Fsublime-import-helper/lists"}