Skip to content

Commit eaf7af7

Browse files
committed
Initial commit
0 parents  commit eaf7af7

File tree

179 files changed

+27103
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

179 files changed

+27103
-0
lines changed

.cfignore

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
.DS_STORE
2+
3+
# Ignore app settings
4+
.idea
5+
.eslintrc.yml
6+
.gitignore
7+
8+
# Ignore app files
9+
gulp.config.js
10+
gulpfile.js
11+
readme.md
12+
webpack.config.js
13+
14+
# Ignore node_modules
15+
node_modules
16+
17+
# Ignore src
18+
src/assets
19+
src/index.js

.editorconfig

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
root = true
2+
3+
# Unix-style newlines with a newline ending every file
4+
[*]
5+
charset = utf-8
6+
end_of_line = lf
7+
trim_trailing_whitespace = true
8+
insert_final_newline = true
9+
indent_style = space
10+
indent_size = 4
11+
12+
[*.yml]
13+
indent_style = space
14+
indent_size = 2
15+
16+
[*.json]
17+
indent_style = space
18+
indent_size = 2

.gitignore

+71
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
8+
# Runtime data
9+
pids
10+
*.pid
11+
*.seed
12+
*.pid.lock
13+
14+
# Directory for instrumented libs generated by jscoverage/JSCover
15+
lib-cov
16+
17+
# Coverage directory used by tools like istanbul
18+
coverage
19+
20+
# nyc test coverage
21+
.nyc_output
22+
23+
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
24+
.grunt
25+
26+
# Bower dependency directory (https://bower.io/)
27+
bower_components
28+
29+
# node-waf configuration
30+
.lock-wscript
31+
32+
# Compiled binary addons (http://nodejs.org/api/addons.html)
33+
build/Release
34+
35+
# Dependency directories
36+
node_modules/
37+
jspm_packages/
38+
package-lock.json
39+
40+
# Typescript v1 declaration files
41+
typings/
42+
43+
# Optional npm cache directory
44+
.npm
45+
46+
# Optional eslint cache
47+
.eslintcache
48+
49+
# Optional REPL history
50+
.node_repl_history
51+
52+
# Output of 'npm pack'
53+
*.tgz
54+
55+
# Yarn Integrity file
56+
.yarn-integrity
57+
58+
# dotenv environment variables file
59+
.env
60+
61+
# Output of build
62+
dist
63+
public
64+
65+
66+
##### OS generated files
67+
.DS_Store
68+
.Spotlight-V100
69+
.Trashes
70+
ehthumbs.db
71+
Thumbs.db

.gitmodules

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[submodule "src/assets/design-system"]
2+
path = src/assets/design-system
3+
url = git@bitbucket.org:newelldigitaltech/toolkit.git
4+
branch = master

LICENSE

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2017 Atomic-Reactor
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

gulp.config.js

+123
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
'use strict';
2+
3+
const path = require('path');
4+
const globby = require('globby');
5+
6+
// Create the webpack entries object.
7+
const entries = pattern => globby.sync(pattern)
8+
.reduce((files, f) => {
9+
let file = path.basename(f, '.js');
10+
files[file] = path.resolve(f);
11+
return files;
12+
}, {});
13+
14+
const globDefineFiles = pattern => globby.sync(pattern)
15+
.reduce((files, f) => {
16+
let cmp = path.basename(path.parse(f).dir);
17+
files[cmp] = f.replace(/^src\/app/, '.').replace(/.js$/, '');
18+
return files;
19+
}, {});
20+
21+
module.exports = () => {
22+
return {
23+
spa: true,
24+
env: "development",
25+
entries: entries(["src/app/*.js"]),
26+
defines: {
27+
"global": "window",
28+
restAPI: JSON.stringify(process.env.REST_API_URL || "https://demo3914762.mockable.io"),
29+
allInitialStates: JSON.stringify(globDefineFiles('src/app/components/**/state.js')),
30+
allRoutes: JSON.stringify(globDefineFiles('src/app/components/**/route.js')),
31+
allActions: JSON.stringify(globDefineFiles('src/app/components/**/actions.js')),
32+
allActionTypes: JSON.stringify(globDefineFiles('src/app/components/**/actionTypes.js')),
33+
allServices: JSON.stringify(globDefineFiles('src/app/components/**/services.js')),
34+
allReducers: JSON.stringify(globDefineFiles('src/app/components/**/reducers.js')),
35+
},
36+
browsers: 'last 1 version',
37+
port: {
38+
browsersync: 3000,
39+
proxy: 3030,
40+
},
41+
cssPreProcessor: 'sass',
42+
watch: {
43+
js: [
44+
"src/app/**/*",
45+
"!{src/assets/design-system,src/assets/design-system/**}",
46+
],
47+
markup: [
48+
"src/**/*.html",
49+
"src/assets/style/**/*.css",
50+
"!{src/assets/design-system,src/assets/design-system/**}",
51+
],
52+
style: [
53+
"src/assets/**/*.less",
54+
"src/assets/**/*.scss",
55+
"src/assets/**/*.sass",
56+
"src/assets/design-system/src/assets/toolkit/styles/**/*.scss",
57+
],
58+
assets: [
59+
"src/assets/**/*",
60+
"!{src/assets/style,src/assets/style/**}",
61+
"!{src/assets/js,src/assets/js/**}",
62+
"!{src/assets/design-system,src/assets/design-system/**}",
63+
],
64+
server: [
65+
"src/index.js",
66+
"src/server/**/*.js",
67+
],
68+
templates: [
69+
"src/server/**/*.hbs",
70+
],
71+
toolkit: {
72+
assets: [
73+
"src/assets/design-system/src/assets/toolkit/**",
74+
"!{src/assets/design-system/src/assets/toolkit/scripts,src/assets/design-system/src/assets/toolkit/scripts/**}",
75+
"!{src/assets/design-system/src/assets/toolkit/styles,src/assets/design-system/src/assets/toolkit/styles/**}",
76+
],
77+
},
78+
},
79+
src: {
80+
app: 'src',
81+
js: [
82+
"src/app/**/*",
83+
"!{src/assets/design-system,src/assets/design-system/**}",
84+
],
85+
markup: [
86+
"src/**/*.html",
87+
"!src/assets/design-system/**",
88+
"!{src/assets/design-system,src/assets/design-system/**}",
89+
],
90+
style: [
91+
"src/assets/style/*.scss",
92+
"!{src/assets/design-system,src/assets/design-system/**}",
93+
],
94+
assets: [
95+
"src/assets/**/*",
96+
"!{src/assets/style,src/assets/style/**}",
97+
"!{src/assets/js,src/assets/js/**}",
98+
"!{src/assets/design-system,src/assets/design-system/**}",
99+
],
100+
toolkit: {
101+
assets: [
102+
"src/assets/design-system/src/assets/toolkit/**",
103+
"!{src/assets/design-system/src/assets/toolkit/scripts,src/assets/design-system/src/assets/toolkit/scripts/**}",
104+
"!{src/assets/design-system/src/assets/toolkit/styles,src/assets/design-system/src/assets/toolkit/styles/**}",
105+
],
106+
},
107+
includes: ["./node_modules", "./src/assets/design-system/node_modules"],
108+
appdir: path.resolve(__dirname, 'src/app'),
109+
rootdir: path.resolve(__dirname),
110+
},
111+
dest: {
112+
server: './',
113+
dist: 'public',
114+
js: 'public/assets/js',
115+
markup: 'public',
116+
style: 'public/assets/style',
117+
assets: 'public/assets',
118+
toolkit: {
119+
assets: 'public/assets'
120+
}
121+
},
122+
};
123+
};

0 commit comments

Comments
 (0)