|
1 | 1 | {
|
2 | 2 | "name": "es7-react-js-snippets",
|
3 |
| - "displayName": "ES7+ React/Redux/GraphQL/React-Native snippets", |
4 |
| - "description": "Simple extensions for React, Redux and Graphql in JS/TS with ES7+ syntax", |
| 3 | + "displayName": "ES7+ React/Redux/React-Native snippets", |
| 4 | + "description": "Extensions for React (React-Native), Redux and GraphQL snippets in JS/TS with ES7+ syntax. Customizable. Built-in integration with prettier.", |
5 | 5 | "version": "3.2.0",
|
6 | 6 | "publisher": "dsznajder",
|
7 | 7 | "icon": "images/logo.png",
|
| 8 | + "browser": "./lib/index.js", |
| 9 | + "main": "./lib/index.js", |
8 | 10 | "keywords": [
|
9 | 11 | "snippets",
|
10 | 12 | "react",
|
11 | 13 | "redux",
|
12 | 14 | "react-native",
|
| 15 | + "customizable", |
13 | 16 | "javascript",
|
14 |
| - "typescript" |
| 17 | + "typescript", |
| 18 | + "prettier" |
15 | 19 | ],
|
16 | 20 | "license": "MIT",
|
17 | 21 | "repository": {
|
18 | 22 | "type": "git",
|
19 | 23 | "url": "https://github.com/dsznajder/vscode-es7-javascript-react-snippets"
|
20 | 24 | },
|
21 | 25 | "engines": {
|
22 |
| - "vscode": "^1.45.0" |
| 26 | + "vscode": "^1.60.0" |
23 | 27 | },
|
24 | 28 | "categories": [
|
25 | 29 | "Snippets"
|
|
28 | 32 | "ui",
|
29 | 33 | "workspace"
|
30 | 34 | ],
|
31 |
| - "browser": "./out/extension.js", |
32 |
| - "main": "./lib/index.js", |
33 | 35 | "capabilities": {
|
34 | 36 | "virtualWorkspaces": true,
|
35 | 37 | "untrustedWorkspaces": {
|
36 | 38 | "supported": true
|
37 | 39 | }
|
38 | 40 | },
|
39 | 41 | "activationEvents": [
|
40 |
| - "onCommand:extension.snippetSearch" |
| 42 | + "onCommand:esReactSnippets.search" |
41 | 43 | ],
|
42 | 44 | "contributes": {
|
43 | 45 | "commands": [
|
44 | 46 | {
|
45 |
| - "command": "extension.snippetSearch", |
46 |
| - "title": "ES7 snippet search" |
| 47 | + "command": "esReactSnippets.search", |
| 48 | + "title": "Snippet search" |
47 | 49 | }
|
48 | 50 | ],
|
49 | 51 | "keybindings": [
|
50 | 52 | {
|
51 |
| - "command": "extension.snippetSearch", |
| 53 | + "command": "esReactSnippets.search", |
52 | 54 | "key": "ctrl+alt+r",
|
53 | 55 | "mac": "shift+cmd+r",
|
54 | 56 | "when": "editorTextFocus"
|
55 | 57 | }
|
56 | 58 | ],
|
| 59 | + "configuration": { |
| 60 | + "title": "ES React/React-Native/Redux snippets", |
| 61 | + "properties": { |
| 62 | + "esReactSnippets.settings.prettierEnabled": { |
| 63 | + "type": "boolean", |
| 64 | + "markdownDescription": "Integrate prettier settings with code generated from snippets.", |
| 65 | + "default": true |
| 66 | + }, |
| 67 | + "esReactSnippets.settings.importReactOnTop": { |
| 68 | + "type": "boolean", |
| 69 | + "markdownDescription": "Controls if snippets should add `import React from 'react';` at the top of components.\nPreviously components like that were used with `_` prefix.", |
| 70 | + "default": true |
| 71 | + }, |
| 72 | + "esReactSnippets.settings.typescript": { |
| 73 | + "type": "boolean", |
| 74 | + "markdownDescription": "Controls if React components have typescript Props typing.", |
| 75 | + "default": false |
| 76 | + }, |
| 77 | + "esReactSnippets.settings.semiColons": { |
| 78 | + "type": "boolean", |
| 79 | + "markdownDescription": "Controls if snippets should use semi colons.\nOnly applies when `#esReactSnippets.settings.prettierEnabled#` is disabled", |
| 80 | + "default": true |
| 81 | + }, |
| 82 | + "esReactSnippets.settings.singleQuote": { |
| 83 | + "type": "boolean", |
| 84 | + "markdownDescription": "Controls if snippets should use single quotes.\nOnly applies when `#esReactSnippets.settings.prettierEnabled#` is disabled", |
| 85 | + "default": true |
| 86 | + }, |
| 87 | + "esReactSnippets.settings.tabWidth": { |
| 88 | + "type": "number", |
| 89 | + "markdownDescription": "Controls how many spaces snippets will have.\nOnly applies when `#esReactSnippets.settings.prettierEnabled#` is disabled", |
| 90 | + "default": 2 |
| 91 | + }, |
| 92 | + "esReactSnippets.settings.componentPropsPrefix": { |
| 93 | + "type": "string", |
| 94 | + "markdownDescription": "Controls which prefix snippets should use for component props.\nOnly applies when `#esReactSnippets.settings.typescript#` is enabled.", |
| 95 | + "default": "type", |
| 96 | + "enum": [ |
| 97 | + "type", |
| 98 | + "interface" |
| 99 | + ] |
| 100 | + } |
| 101 | + } |
| 102 | + }, |
57 | 103 | "snippets": [
|
58 | 104 | {
|
59 | 105 | "language": "javascript",
|
|
82 | 128 | ]
|
83 | 129 | },
|
84 | 130 | "scripts": {
|
85 |
| - "vscode:prepublish": "yarn run package", |
86 |
| - "compile": "tsc -p ./ --noEmit false --outDir lib/", |
87 |
| - "compile:web": "webpack --mode production --devtool hidden-source-map", |
| 131 | + "vscode:prepublish": "yarn compile", |
| 132 | + "compile": "rm -rf lib; tsc -p ./ --noEmit false --module commonjs --outDir lib", |
| 133 | + "lint": "eslint --ext .js,.ts,.tsx ./src/", |
88 | 134 | "watch": "tsc -watch -p ./",
|
89 |
| - "watch:web": "webpack --watch", |
90 |
| - "package": "yarn compile && webpack --mode production --devtool hidden-source-map", |
91 | 135 | "typescript": "tsc --noEmit"
|
92 | 136 | },
|
93 | 137 | "dependencies": {
|
| 138 | + "prettier": "2.5.1", |
94 | 139 | "vscode": "1.1.37"
|
95 | 140 | },
|
96 | 141 | "devDependencies": {
|
97 |
| - "@types/node": "16.9.6", |
98 |
| - "@types/vscode": "1.60.0", |
99 |
| - "eslint": "7.32.0", |
| 142 | + "@babel/cli": "7.16.0", |
| 143 | + "@babel/preset-typescript": "7.16.5", |
| 144 | + "@types/node": "17.0.4", |
| 145 | + "@types/prettier": "2.4.2", |
| 146 | + "@types/vscode": "1.63.1", |
| 147 | + "esbuild": "0.14.8", |
| 148 | + "eslint": "8.5.0", |
100 | 149 | "eslint-config-satya164": "3.1.10",
|
101 | 150 | "eslint-plugin-simple-import-sort": "7.0.0",
|
102 |
| - "prettier": "2.4.1", |
103 |
| - "ts-loader": "^9.2.6", |
104 |
| - "typescript": "4.4.3", |
105 |
| - "webpack": "^5.64.4", |
106 |
| - "webpack-cli": "^4.9.1" |
| 151 | + "prettier": "2.5.1", |
| 152 | + "typescript": "4.5.4" |
107 | 153 | },
|
108 | 154 | "prettier": {
|
109 | 155 | "bracketSameLine": false,
|
|
0 commit comments