Skip to content

Commit a338295

Browse files
author
Alex Lee
authored
Merge pull request #18 from alexlee-dev/website
Website
2 parents f547bb4 + b5a9709 commit a338295

50 files changed

Lines changed: 15127 additions & 0 deletions

Some content is hidden

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

website/.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
cypress/

website/.eslintrc.js

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
module.exports = {
2+
env: {
3+
browser: true,
4+
es6: true,
5+
node: true,
6+
},
7+
extends: [
8+
'airbnb-base',
9+
'eslint:recommended',
10+
'plugin:react/recommended',
11+
'plugin:@typescript-eslint/eslint-recommended',
12+
'plugin:@typescript-eslint/recommended',
13+
'prettier',
14+
],
15+
globals: {
16+
Atomics: 'readonly',
17+
SharedArrayBuffer: 'readonly',
18+
},
19+
parser: '@typescript-eslint/parser',
20+
parserOptions: {
21+
ecmaFeatures: {
22+
jsx: true,
23+
},
24+
ecmaVersion: 2018,
25+
sourceType: 'module',
26+
},
27+
plugins: ['@typescript-eslint', 'react'],
28+
settings: {
29+
'import/extensions': ['.js', '.ts'],
30+
'import/resolver': {
31+
node: {
32+
extensions: ['.js', '.ts', '.jsx', '.tsx'],
33+
},
34+
},
35+
react: {
36+
version: 'detect',
37+
},
38+
},
39+
overrides: [
40+
{
41+
files: ['**/*.tsx'],
42+
rules: {
43+
'react/prop-types': 'off',
44+
},
45+
},
46+
],
47+
rules: {
48+
'import/extensions': [
49+
'warn',
50+
'always',
51+
{
52+
ts: 'never',
53+
tsx: 'never',
54+
js: 'never',
55+
jsx: 'never',
56+
},
57+
],
58+
'react/jsx-filename-extension': [
59+
1,
60+
{ extensions: ['.js', '.jsx', '.ts', '.tsx'] },
61+
],
62+
'no-return-assign': 0,
63+
'import/prefer-default-export': 0,
64+
'import/no-unresolved': 1,
65+
},
66+
};

website/.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
node_modules/
2+
build/
3+
dist
4+
cypress/screenshots/
5+
cypress/videos/
6+
.env-cmdrc.json

website/.prettierignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
build/
2+
dist/

website/.prettierrc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"arrowParens": "always",
3+
"singleQuote": true,
4+
"trailingComma": "all"
5+
}

website/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# create-cli-application website
2+
3+
Website for `create-cli-application`

website/cypress.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"video": false
3+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"name": "Using fixtures to represent data",
3+
"email": "hello@cypress.io",
4+
"body": "Fixtures are a great way to mock data for responses to routes"
5+
}
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
/// <reference types="cypress" />
2+
3+
context('create-cli-application', () => {
4+
beforeEach(() => {
5+
cy.visit('http://localhost:3000');
6+
});
7+
8+
it('Should display correct content', () => {
9+
cy.get('body').should('contain.text', 'create-cli-application');
10+
cy.get('body').should(
11+
'contain.text',
12+
'A bootstrapper for creating a cli application with Node.',
13+
);
14+
cy.get('body').should('contain.text', '15.6kb gzipped');
15+
cy.get('body').should('contain.text', 'View Documentation');
16+
});
17+
18+
it('Should step through demo', () => {
19+
cy.get('#create-application').click();
20+
cy.wait(10000);
21+
cy.get('#start-application').click();
22+
cy.wait(10000);
23+
cy.get('#view-documentation').should('exist');
24+
});
25+
});

website/cypress/plugins/index.js

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/// <reference types="cypress" />
2+
// ***********************************************************
3+
// This example plugins/index.js can be used to load plugins
4+
//
5+
// You can change the location of this file or turn off loading
6+
// the plugins file with the 'pluginsFile' configuration option.
7+
//
8+
// You can read more here:
9+
// https://on.cypress.io/plugins-guide
10+
// ***********************************************************
11+
12+
// This function is called when a project is opened or re-opened (e.g. due to
13+
// the project's config changing)
14+
15+
/**
16+
* @type {Cypress.PluginConfig}
17+
*/
18+
module.exports = (on, config) => {
19+
// `on` is used to hook into various events Cypress emits
20+
// `config` is the resolved Cypress config
21+
};

0 commit comments

Comments
 (0)