package.json 3.71 KB
Newer Older
Diego Sampaio's avatar
Diego Sampaio committed
1
{
2
	"name": "@rocket.chat/livechat",
3
	"version": "1.0.0",
4
	"license": "MIT",
Tasso Evangelista's avatar
Tasso Evangelista committed
5 6 7 8
	"repository": {
		"type": "git",
		"url": "https://github.com/RocketChat/Rocket.Chat.Livechat"
	},
9 10
	"scripts": {
		"start": "if-env NODE_ENV=production && npm run -s serve || npm run -s dev",
11 12
		"build:app": "GENERATE_SOURCEMAP=false preact build --no-prerender --optimize-minimize",
		"build:widget": "webpack-cli src/widget.js -o build/rocketchat-livechat.min.js --mode production",
13
		"build:pack": "cp widget-demo.html ./build && tar -C build -czf build.tar.gz '.'",
14
		"build": "run-s build:app build:widget build:pack",
15 16 17 18 19 20 21 22
		"serve": "preact build --no-prerender --optimize-minimize && preact serve",
		"dev": "preact watch",
		"lint": "eslint src",
		"test": "jest ./tests",
		"coverage": "jest --coverage",
		"storybook": "start-storybook -p 9001 -c .storybook",
		"i18n": "i18nline synch && node_modules/.bin/eslint --fix src/i18n/index.js",
		"deploy-storybook": "storybook-to-ghpages",
Tasso Evangelista's avatar
Tasso Evangelista committed
23 24
		"bundle-analyzer": "webpack-bundle-analyzer build/stats.json",
		"release": "gh-release -c master --assets build.tar.gz"
25 26 27 28 29
	},
	"eslintIgnore": [
		"build/*"
	],
	"devDependencies": {
30 31
		"@storybook/addon-a11y": "5.0.1",
		"@storybook/addon-actions": "^5.0.1",
32
		"@storybook/addon-backgrounds": "^5.0.3",
33 34 35 36 37
		"@storybook/addon-centered": "^5.0.1",
		"@storybook/addon-knobs": "^5.0.1",
		"@storybook/addon-options": "^5.0.1",
		"@storybook/addon-viewport": "^5.0.1",
		"@storybook/react": "^5.0.1",
38
		"@storybook/storybook-deployer": "^2.3.0",
39 40
		"@storybook/theming": "^5.0.1",
		"create-react-ref": "^0.1.0",
Tasso Evangelista's avatar
Tasso Evangelista committed
41
		"css-loader": "^2.1.0",
42
		"desvg-loader": "^0.1.0",
Tasso Evangelista's avatar
Tasso Evangelista committed
43 44
		"eslint": "^5.12.1",
		"eslint-config-synacor": "^3.0.3",
Tasso Evangelista's avatar
Tasso Evangelista committed
45
		"gh-release": "^3.5.0",
46
		"husky": "^1.3.1",
47 48 49
		"identity-obj-proxy": "^3.0.0",
		"if-env": "^1.0.0",
		"image-webpack-loader": "^4.3.1",
Tasso Evangelista's avatar
Tasso Evangelista committed
50
		"jest": "^24.0.0",
51 52
		"lorem-ipsum": "^1.0.6",
		"node-sass": "^4.9.3",
53
		"npm-run-all": "^4.1.5",
Tasso Evangelista's avatar
Tasso Evangelista committed
54
		"preact-cli": "3.0.0-next.14",
55 56
		"preact-compat": "^3.18.4",
		"preact-render-spy": "^1.2.1",
Tasso Evangelista's avatar
Tasso Evangelista committed
57
		"prompts": "^2.0.1",
58
		"sass-loader": "^7.1.0",
Tasso Evangelista's avatar
Tasso Evangelista committed
59
		"style-loader": "^0.23.1",
60
		"svg-loader": "0.0.2",
61 62
		"webpack-bundle-analyzer": "^3.0.2",
		"webpack-cli": "^3.2.1"
63 64 65
	},
	"dependencies": {
		"@kossnocorp/desvg": "^0.2.0",
66
		"@rocket.chat/sdk": "^1.0.0-alpha.28",
67 68 69
		"date-fns": "^1.29.0",
		"desvg": "^1.0.2",
		"fast-async": "^6.3.8",
70
		"history": "^4.7.2",
71 72 73
		"i18n": "^0.8.3",
		"i18nline": "^2.0.1",
		"markdown-it": "^8.4.2",
74
		"mem": "^4.2.0",
75 76 77 78 79
		"msgpack": "^1.0.2",
		"preact": "^8.2.6",
		"preact-context": "^1.1.1",
		"preact-i18nline": "^2.0.0",
		"preact-router": "^2.5.7",
80
		"query-string": "6.3.0",
81 82
		"tiny-events": "^1.0.1",
		"wolfy87-eventemitter": "^5.2.5"
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
	},
	"jest": {
		"verbose": true,
		"setupFiles": [
			"<rootDir>/src/tests/__mocks__/browserMocks.js"
		],
		"testURL": "http://localhost:8080",
		"moduleFileExtensions": [
			"js",
			"jsx"
		],
		"moduleDirectories": [
			"node_modules"
		],
		"moduleNameMapper": {
			"\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/src/tests/__mocks__/fileMock.js",
			"\\.(css|less|scss)$": "identity-obj-proxy",
			"^./style$": "identity-obj-proxy",
			"^preact$": "<rootDir>/node_modules/preact/dist/preact.min.js",
			"^react$": "preact-compat",
			"^react-dom$": "preact-compat",
			"^create-react-class$": "preact-compat/lib/create-react-class",
			"^react-addons-css-transition-group$": "preact-css-transition-group"
		}
	},
	"browserslist": [
		"> 1%",
		"last 2 versions",
		"not ie < 11"
112 113 114 115 116
	],
	"storybook-deployer": {
		"gitUsername": "Guilherme Gazzo",
		"gitEmail": "guilherme.gazzo@rocket.chat",
		"commitMessage": "Deploy Storybook to GitHub Pages [skip ci]"
117 118 119
	},
	"husky": {
		"hooks": {
Tasso Evangelista's avatar
Tasso Evangelista committed
120
			"pre-commit": "run-s i18n && git add -A src/i18n"
121
		}
122
	}
Diego Sampaio's avatar
Diego Sampaio committed
123
}