Nodejs
nodejs snippets and bindings for Sublime Text 3
Details
Installs
- Total 369K
- Win 221K
- Mac 90K
- Linux 59K
Nov 6 | Nov 5 | Nov 4 | Nov 3 | Nov 2 | Nov 1 | Oct 31 | Oct 30 | Oct 29 | Oct 28 | Oct 27 | Oct 26 | Oct 25 | Oct 24 | Oct 23 | Oct 22 | Oct 21 | Oct 20 | Oct 19 | Oct 18 | Oct 17 | Oct 16 | Oct 15 | Oct 14 | Oct 13 | Oct 12 | Oct 11 | Oct 10 | Oct 9 | Oct 8 | Oct 7 | Oct 6 | Oct 5 | Oct 4 | Oct 3 | Oct 2 | Oct 1 | Sep 30 | Sep 29 | Sep 28 | Sep 27 | Sep 26 | Sep 25 | Sep 24 | Sep 23 | Sep 22 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Windows | 0 | 13 | 3 | 7 | 8 | 3 | 10 | 4 | 9 | 7 | 11 | 10 | 6 | 10 | 13 | 17 | 7 | 8 | 10 | 3 | 12 | 6 | 9 | 6 | 4 | 2 | 6 | 7 | 5 | 6 | 9 | 5 | 7 | 9 | 5 | 10 | 8 | 7 | 8 | 12 | 2 | 8 | 8 | 14 | 8 | 3 |
Mac | 0 | 2 | 2 | 1 | 1 | 0 | 2 | 2 | 4 | 1 | 1 | 3 | 3 | 4 | 2 | 4 | 2 | 1 | 0 | 2 | 5 | 2 | 5 | 2 | 1 | 1 | 0 | 5 | 2 | 3 | 2 | 3 | 1 | 1 | 1 | 1 | 1 | 3 | 4 | 1 | 1 | 1 | 6 | 4 | 3 | 3 |
Linux | 0 | 1 | 3 | 1 | 2 | 0 | 3 | 5 | 3 | 5 | 1 | 1 | 2 | 2 | 1 | 2 | 4 | 1 | 1 | 4 | 5 | 3 | 2 | 3 | 0 | 1 | 6 | 1 | 3 | 4 | 9 | 3 | 2 | 3 | 5 | 5 | 4 | 5 | 4 | 2 | 4 | 1 | 6 | 3 | 7 | 0 |
Readme
- Source
- raw.githubusercontent.com
Nodejs Sublime Text 3 Package
Overview
The Nodejs Sublime Text 3 Package provides a set of code completion, scripts and tools to work with nodejs.
Code Completion
The package code completion is generated from the main nodejs libraries and global namespaces. To invoke
the code completion start typing the namespace you want (For example, type fs
) and then Ctrl + Space, you get this:
Node Commands
You can access node commands in two ways.
- Via the menu in
Tools -> Node
- By accessing the Command Palette and typing
node
The current commands available are (with Windows binding, other bindings are provided):
- Run current script in node (Alt + R)
- Run current script in node debug (Alt + D)
- Run current script in node and arguments (Ctrl + Alt + r)
- Run current script in node debug and arguments (Ctrl + Alt + D)
- Uglify Code
- NPM Command
- Build documentation (builds the completion files)
Snippets
Also included are some boilerplate snippets. They include functionality such as a http server, reading the contents of a directory, etc.
To access these snippets type node
in your editor followed by Ctrl + Space
If you have any boilerplate code you would like to see in here, get in touch.
Install
You can install this package from Sublime Text 3 package manager. Also you can install this package manually:
MacOSX
`git clone https://github.com/tanepiper/SublimeText-Nodejs.git ~/Library/Application\ Support/Sublime\ Text\ 3/Packages/Nodejs`
Windows
`git clone https://github.com/tanepiper/SublimeText-Nodejs "%APPDATA%\Sublime Text 3\Packages\Nodejs"`
Linux
`git clone https://github.com/tanepiper/SublimeText-Nodejs $HOME/.config/sublime-text-3/Packages/Nodejs`
After the package is installed, install Node.js packages needed for working the package built-in tools. You can to install either globaly by: npm install -g commander@"~2.9.0" uglify-js@"~2.6.0"
or localy by adding previously mentioned Node.js packages to your current project, either: npm install commander@"~2.9.0" uglify-js@"~2.6.0"
or manully editing your project package.json
file.
PLEASE NOTE: When your installed Node.js packages (previously mentioned) globaly, you also need to set the package node_path
setting. For that, go to the Preferences -> Package Settings -> Nodejs -> Settings User
.
Build Systems
PLEASE NOTE: The build system will be refactored to provide different nodejs build systems (such as jake)
If you have a JavaScript file open, by selecting Tools -> Build Systems -> Nodejs
and
then hitting Ctrl + B, you will activate the node build system on your file and node will try to run it.
You may need to add a path
variable to the settings object for this if your node executable is not found
TODO
uglify_js.js and other ./tools/*.js scripts dosen't work when the package is installed by SublimeText package managerUse events API to install NodeJs dependicies for tools provided by the packageRefactor plugin's classes inheritance in Nodejs.pyUse events API to generate Sublime Text completions during installation phase depending on a version of installed NodeJsCheck for nvm installation- Replace the Nodejs.sublime-build to work with jake
Reorganise menu structureImprove code completion snippets where possible- Provide an interface for writing JavaScript plugins
Author & Contributors
The original author of this package Tane Piper. At the time the project maintainer is Vardan Pogosian.