Observed since 20 Oct, 19:23 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
30s
A command-line application for 30 seconds of code snippets
A command-line application for 30 seconds of code snippets.

Pick one of the following options to install the command-line application:
npm install -g 30s
yarn add -g 30s
$ git clone git@github.com:sQVe/30s.git
$ cd 30s/
$ npm install
$ node lib/index.js <command> <query>
| Short version | Long version | Description |
|---|---|---|
r | random | View random snippet |
s | search | Fuzzy search (RegExp) snippets by id |
t | tag | View snippets by tag |
v | view | View snippet with id |
* | View snippet with id |
| Short version | Long version | Description |
|---|---|---|
-c | --cp | Copy snippet code to clipboard |
-j | --json | Print output in JSON format |
-l | --layout | Print output with specified layout (default: "itced") |
-h | --help | Output usage information |
| Layout key | Description |
|---|---|
i | Output snippet id |
t | Output snippet tags |
c | Output snippet code |
e | Output snippet examples |
d | Output snippet description |
| Example | Description |
|---|---|
30s head | View snippet with id head |
30s v head | View snippet with id head |
30s view head | View snippet with id head |
30s r | View random snippet |
30s random | View random snippet |
30s t array | View snippets by tag array |
30s tag array | View snippets by tag array |
30s s all | Find all snippets with an id that contains all |
30s search all | Find all snippets with an id that contains all |
30s view merge --cp | View snippet with id merge and copy its code |
30s view merge --json | View snippet with id merge and output as JSON |
30s search all --layout ce | Find all snippets with an id that contains all and output code and example |
Please use the issue tracker to report bugs or file feature requests.
Pull requests are more than welcome. Do the following to start helping out:
npm install in the created directory to install all necessary dependencies.Optional steps:
30s if it's already installed: npm uninstall -g 30snpm linkTry to follow functional programming best practices. Use pure functions and Ramda when possible.
Write commits following: Angular Commit Message Conventions. This enables us to automatically release new versions together with semantic-release on fix and feat commit types.
prettier and eslint-config-sqve (a config based on standardjs) enforces our styling and formatting. It runs automatically on pre-commit and is also checked for issues on Travis CI.
See the development board for a detailed development roadmap. Below are a short outline of important improvements:
omelettecommander with basic yargs and own logicA big thank you to the core team and all the contributers at 30-seconds-of-code for creating an awesome curated collection of snippets.
Creative Commons License
CC0 1.0 Universal
Download counts and popularity will appear here as the collector receives them.
| Package / target | Requirement | Relationship |
|---|---|---|
@babel/polyfillEnvironment{
"local_name": "@babel/polyfill",
"alias": false,
"peer_metadata": null
} | ~7.0.0 | runtime |
chalkEnvironment{
"local_name": "chalk",
"alias": false,
"peer_metadata": null
} | ~2.4.1 | runtime |
cli-highlightEnvironment{
"local_name": "cli-highlight",
"alias": false,
"peer_metadata": null
} | ~2.0.0 | runtime |
clipboardyEnvironment{
"local_name": "clipboardy",
"alias": false,
"peer_metadata": null
} | ~1.2.3 | runtime |
commanderEnvironment{
"local_name": "commander",
"alias": false,
"peer_metadata": null
} | ~2.19.0 | runtime |
markedEnvironment{
"local_name": "marked",
"alias": false,
"peer_metadata": null
} | ~0.5.1 | runtime |
marked-terminalEnvironment{
"local_name": "marked-terminal",
"alias": false,
"peer_metadata": null
} | ~3.1.1 | runtime |
ramdaEnvironment{
"local_name": "ramda",
"alias": false,
"peer_metadata": null
} | ~0.26.0 | runtime |
@babel/cliEnvironment{
"local_name": "@babel/cli",
"alias": false,
"peer_metadata": null
} | ~7.2.0 | development |
@babel/coreEnvironment{
"local_name": "@babel/core",
"alias": false,
"peer_metadata": null
} | ~7.2.0 | development |
@babel/nodeEnvironment{
"local_name": "@babel/node",
"alias": false,
"peer_metadata": null
} | ~7.2.0 | development |
@babel/preset-envEnvironment{
"local_name": "@babel/preset-env",
"alias": false,
"peer_metadata": null
} | ~7.2.0 | development |
@types/jestEnvironment{
"local_name": "@types/jest",
"alias": false,
"peer_metadata": null
} | ^23.3.7 | development |
@types/nodeEnvironment{
"local_name": "@types/node",
"alias": false,
"peer_metadata": null
} | ^10.12.2 | development |
@types/ramdaEnvironment{
"local_name": "@types/ramda",
"alias": false,
"peer_metadata": null
} | ~0.25.41 | development |
babel-coreEnvironment{
"local_name": "babel-core",
"alias": false,
"peer_metadata": null
} | 7.0.0-bridge.0 | development |
babel-jestEnvironment{
"local_name": "babel-jest",
"alias": false,
"peer_metadata": null
} | ~23.6.0 | development |
coverallsEnvironment{
"local_name": "coveralls",
"alias": false,
"peer_metadata": null
} | ~3.0.2 | development |
eslintEnvironment{
"local_name": "eslint",
"alias": false,
"peer_metadata": null
} | ~5.10.0 | development |
eslint-config-sqveEnvironment{
"local_name": "eslint-config-sqve",
"alias": false,
"peer_metadata": null
} | ~2.0.0 | development |
eslint-config-standardEnvironment{
"local_name": "eslint-config-standard",
"alias": false,
"peer_metadata": null
} | ~12.0.0 | development |
eslint-config-standard-reactEnvironment{
"local_name": "eslint-config-standard-react",
"alias": false,
"peer_metadata": null
} | ~7.0.2 | development |
eslint-plugin-fpEnvironment{
"local_name": "eslint-plugin-fp",
"alias": false,
"peer_metadata": null
} | ~2.3.0 | development |
eslint-plugin-importEnvironment{
"local_name": "eslint-plugin-import",
"alias": false,
"peer_metadata": null
} | ~2.14.0 | development |
eslint-plugin-nodeEnvironment{
"local_name": "eslint-plugin-node",
"alias": false,
"peer_metadata": null
} | ~8.0.0 | development |
eslint-plugin-promiseEnvironment{
"local_name": "eslint-plugin-promise",
"alias": false,
"peer_metadata": null
} | ~4.0.1 | development |
eslint-plugin-reactEnvironment{
"local_name": "eslint-plugin-react",
"alias": false,
"peer_metadata": null
} | ~7.11.1 | development |
eslint-plugin-standardEnvironment{
"local_name": "eslint-plugin-standard",
"alias": false,
"peer_metadata": null
} | ~4.0.0 | development |
huskyEnvironment{
"local_name": "husky",
"alias": false,
"peer_metadata": null
} | ~1.3.0 | development |
jestEnvironment{
"local_name": "jest",
"alias": false,
"peer_metadata": null
} | ~23.6.0 | development |
lint-stagedEnvironment{
"local_name": "lint-staged",
"alias": false,
"peer_metadata": null
} | ~8.1.0 | development |
prettierEnvironment{
"local_name": "prettier",
"alias": false,
"peer_metadata": null
} | ~1.15.2 | development |
prettier-eslint-cliEnvironment{
"local_name": "prettier-eslint-cli",
"alias": false,
"peer_metadata": null
} | ~4.7.1 | development |
semantic-releaseEnvironment{
"local_name": "semantic-release",
"alias": false,
"peer_metadata": null
} | ~15.13.1 | development |
Source distribution
{
"integrity": "sha512-WmL6I7eqsKv530uFgGTUAeDIRKReKr2Z5kdRZIBT+mgXZBUGW8VC11i0gQhSm/DqkqVcq4d7/d60ROZ2VnCtow==",
"shasum": "f703925dea0def17c0c45a1693ab2030e06f1c12",
"tarball": "https://registry.npmjs.org/30s/-/30s-1.0.5.tgz",
"fileCount": 9,
"unpackedSize": 261536,
"npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcYB8xCRA9TVsSAnZWagAAJCkP/2spv8DGnL9UwLnyxAMD\ndRvd62uXIps+5DlyXOjZommGyObsd7d/x6Lfd9oy9sJ3GrhRWEsJK9fcxJsQ\noX8s9PmCn9ePXfxsYnkbBLQenF64Net1kp6iotLYbzsA1gi3bx7Eoqw1QjiO\nIrbon2K2AG9KbAqmNlaJg3aDr148J8S+d5djC0GMEz6FvHNKDiL7mC+liFSp\nw3S01QiS3LGyjn0pMsCd0dQRv9fe1hdK1oQQg7XgpQgWmvw8Gy+41YIrHNlO\n7wB4rkn0bg4DJPsrj7jShRV4FpGOEhtQTn+ivkqjdBA1D+LLRxBSmXBa5NQn\njS8fJGMaAA6HTrjPnT+4yggxZjHQCPibro19fWq1nplPlJlDkkVvYkNZ20Cp\nc4tTJ952FDoYNLbbSLZ6Gcxpk/xFR/xTDAIAp3I3TGGMYnkzD2AQGikC1z0l\nCNOHXeEcJDlC/XsYzKJpGEQfY5K0gvh/9d0uvOVAM3wjGjA2/ePrCbeDwsih\nssKOV5DN5EVSbjrtVOT45+K7CzCVpFF9VK6imLX6A7pm/1sqc3/evD5dkU9l\nTm3yT3vgQouAhxbr/CiK1eb6MD9jAQnUo0aO8MX33ab7HS6v1Rw+xpE9xxHt\newIUpmN4bOXqms6L/JNVfAICQ6m1RFAm5ArCuplWjd3XEmZqjDuRZtfEJ1zN\nhSkk\r\n=Z3jx\r\n-----END PGP SIGNATURE-----\r\n",
"signatures": [
{
"keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA",
"sig": "MEUCIGD36anbtQoEH9eqnbCgKQkWP1Xk1z73HDUS7YQL3SF/AiEA3ONeW/zM8PyyzTyRWYjTqsDiJewiP65JR8fWxMMD0HI="
}
]
}Shared repository data · GitHub
Observed since 20 Oct, 19:23 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package_version:664a3790c8075a3f5168946f82045cf16cd9e4d5ff077edb8b46be16b2cc23a7