Skip to content

Commit

Permalink
chore: setup project
Browse files Browse the repository at this point in the history
  • Loading branch information
fernandopasik committed Oct 9, 2018
1 parent d564255 commit d8aa00d
Show file tree
Hide file tree
Showing 13 changed files with 9,920 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# EditorConfig helps developers define and maintain consistent
# coding styles between different editors and IDEs
# http://editorconfig.org

root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[*{.html,.php}]
indent_style = tab

[*.md]
trim_trailing_whitespace = false

[*.yml]
indent_size = 2
indent_style = space

[{package.json}]
# The indent size used in the `package.json` file cannot be changed
# https://github.com/npm/npm/pull/3180#issuecomment-16336516
indent_size = 2
indent_style = space
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
lib
39 changes: 39 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"extends": [ "airbnb-base" ],
"parser": "typescript-eslint-parser",
"env": {
"browser": true
},
"plugins": [ "typescript" ],
"settings": {
"import/resolver": {
"node": {
"extensions": [ ".ts", ".js" ]
}
}
},
"rules": {
"class-methods-use-this": "off",
"no-undef": "off",
"import/extensions": [".js", ".jsx", ".json", ".ts", ".tsx"],
"import/prefer-default-export": "off",
"typescript/member-ordering": "error",
"typescript/adjacent-overload-signatures": "error",
"typescript/no-angle-bracket-type-assertion": "error",
"typescript/no-array-constructor": "error",
"typescript/no-empty-interface": "error",
"typescript/no-explicit-any": "error",
"typescript/no-inferrable-types": "off",
"typescript/no-namespace": "off",
"typescript/class-name-casing": "error",
"typescript/no-non-null-assertion": "error",
"typescript/no-parameter-properties": "error",
"typescript/no-triple-slash-reference": "error",
"typescript/no-type-alias": "error",
"typescript/no-unused-vars": "error",
"typescript/no-use-before-define": "error",
"typescript/no-var-requires": "error",
"typescript/prefer-namespace-keyword": "off",
"typescript/type-annotation-spacing": "error"
}
}
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* text=auto
22 changes: 22 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Folder view configuration files
.DS_Store
Desktop.ini

# Thumbnail cache files
._*
Thumbs.db

# Files that might appear on external disks
.Spotlight-V100
.Trashes

# npm
node_modules
npm-debug.log
yarn-error.log

# test files
coverage

# build and temp folders
lib
6 changes: 6 additions & 0 deletions .huskyrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"hooks": {
"commit-msg": "commitlint -e $GIT_PARAMS",
"pre-push": "yarn build"
}
}
22 changes: 22 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Folder view configuration files
.DS_Store
Desktop.ini

# Thumbnail cache files
._*
Thumbs.db

# Files that might appear on external disks
.Spotlight-V100
.Trashes

# npm
node_modules
npm-debug.log
yarn-error.log

# test files
coverage

# build and temp folders
!lib
14 changes: 14 additions & 0 deletions example/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, minimum-scale=1, initial-scale=1, user-scalable=yes">

<title>Lit Redux Router</title>
<meta name="description" content="Declarative routing elements made with lit-html enabled by pwa-helpers and redux">
</head>
<body>
<script src="../node_modules/@webcomponents/webcomponentsjs/webcomponents-loader.js"></script>
</body>
</html>
57 changes: 57 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
{
"name": "lit-redux-router",
"version": "0.0.0",
"description": "Application router based on pwa-helpers using redux and lit-element",
"keywords": [
"react",
"reactjs",
"children",
"utils",
"utilities"
],
"homepage": "https://github.com/fernandopasik/lit-redux-router",
"bugs": "https://github.com/fernandopasik/lit-redux-router/issues",
"license": "MIT",
"author": "Fernando Pasik <[email protected]> (https://fernandopasik.com)",
"contributors": [],
"repository": {
"type": "git",
"url": "https://github.com/fernandopasik/lit-redux-router.git"
},
"main": "lib/index.js",
"scripts": {
"start": "polymer serve",
"build": "tsc",
"prebuild": "yarn lint && yarn del lib",
"lint": "eslint . --ext ts",
"preversion": "yarn build"
},
"dependencies": {
"regexparam": "^1.0.1"
},
"peerDependencies": {
"@polymer/lit-element": "^0.6.2",
"lit-html": "^0.12.0",
"pwa-helpers": "^0.9.0-pre.2",
"redux": "^4.0.0"
},
"devDependencies": {
"@commitlint/cli": "^7.2.0",
"@commitlint/config-conventional": "^7.1.2",
"@polymer/lit-element": "^0.6.2",
"@webcomponents/webcomponentsjs": "^2.1.3",
"del-cli": "^1.1.0",
"eslint": "^5.6.1",
"eslint-config-airbnb-base": "^13.1.0",
"eslint-plugin-import": "^2.14.0",
"eslint-plugin-typescript": "^0.12.0",
"husky": "^1.1.1",
"lit-html": "^0.12.0",
"npm-run-all": "^4.1.3",
"polymer-cli": "^1.8.0",
"pwa-helpers": "^0.9.0-pre.2",
"redux": "^4.0.0",
"typescript": "^3.1.1",
"typescript-eslint-parser": "^20.0.0"
}
}
18 changes: 18 additions & 0 deletions polymer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"entrypoint": "example/index.html",
"shell": "example/app.js",
"builds": [{
"name": "lit-redux-router",
"preset": "es5-unbundled"
}],
"moduleResolution": "node",
"npm": true,
"lint": {
"rules": [
"polymer-3"
],
"filesToIgnore": [
"lib/*"
]
}
}
Empty file added src/index.ts
Empty file.
25 changes: 25 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"compilerOptions": {
"declaration": true,
"declarationMap": true,
"experimentalDecorators": true,
"inlineSources": true,
"lib": ["es2017", "dom"],
"module": "es2015",
"moduleResolution": "node",
"noFallthroughCasesInSwitch": true,
"noImplicitAny": false,
"noImplicitReturns": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"outDir": "lib",
"rootDir": "src",
"skipLibCheck": true,
"sourceMap": true,
"strict": true,
"target": "es2017"
},
"include": [
"src/*.ts"
]
}
Loading

0 comments on commit d8aa00d

Please sign in to comment.