Skip to content

Commit

Permalink
cleanup config
Browse files Browse the repository at this point in the history
  • Loading branch information
JugglerX committed Dec 13, 2018
1 parent bcbbfb8 commit 8e71360
Show file tree
Hide file tree
Showing 8 changed files with 42 additions and 62 deletions.
47 changes: 18 additions & 29 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,30 +1,19 @@
module.exports = {
"parser": "babel-eslint",
"extends": [
"airbnb",
],
"plugins": [

],
"rules": {
"prettier/prettier": [
"error",
{
"singleQuote": true,
"trailingComma": "all",
}
],
"react/prefer-stateless-function": "off",
"react/jsx-filename-extension": "off",
"no-use-before-define": "off",
"react/jsx-closing-bracket-location": "off",
"react/jsx-curly-spacing": "off",
"react/jsx-equals-spacing": "off",
"react/jsx-first-prop-new-line": "off",
"react/jsx-indent": "off",
"react/jsx-indent-props": "off",
"react/jsx-max-props-per-line": "off",
"react/jsx-tag-spacing": "off",
"react/jsx-wrap-multilines": "off"
}
}
parser: 'babel-eslint',
extends: ['airbnb'],
plugins: [],
rules: {
'react/prefer-stateless-function': 'off',
'react/jsx-filename-extension': 'off',
'no-use-before-define': 'off',
'react/jsx-closing-bracket-location': 'off',
'react/jsx-curly-spacing': 'off',
'react/jsx-equals-spacing': 'off',
'react/jsx-first-prop-new-line': 'off',
'react/jsx-indent': 'off',
'react/jsx-indent-props': 'off',
'react/jsx-max-props-per-line': 'off',
'react/jsx-tag-spacing': 'off',
'react/jsx-wrap-multilines': 'off',
},
}
4 changes: 2 additions & 2 deletions gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ module.exports = {
],
},
plugins: [
'gatsby-plugin-sass',
'gatsby-transformer-json',
'gatsby-transformer-remark',
{
resolve: 'gatsby-source-filesystem',
Expand All @@ -34,8 +36,6 @@ module.exports = {
name: 'pages',
},
},
'gatsby-plugin-sass',
'gatsby-transformer-json',
{
resolve: 'gatsby-source-filesystem',
options: {
Expand Down
33 changes: 15 additions & 18 deletions gatsby-node.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
const path = require('path');

// Create pages from markdown files in the /src/pages/services directory using the template /src/templates/service.js
// Create pages from markdown files
exports.createPages = ({ graphql, actions }) => {
const { createPage } = actions;
return new Promise((resolve, reject) => {
/* eslint-disable */
resolve(
graphql(
`
Expand Down Expand Up @@ -58,42 +57,40 @@ exports.createPages = ({ graphql, actions }) => {
}
}
}
`
).then(result => {
console.log(result)
`,
).then((result) => {
result.data.services.edges.forEach(({ node }) => {
let component = path.resolve('src/templates/service.js')
const component = path.resolve('src/templates/service.js');
createPage({
path: node.frontmatter.path,
component,
context: {
id: node.id,
},
})
})
});
});
result.data.team.edges.forEach(({ node }) => {
let component = path.resolve('src/templates/team.js')
const component = path.resolve('src/templates/team.js');
createPage({
path: node.frontmatter.path,
component,
context: {
id: node.id,
},
})
})
});
});
result.data.testimonials.edges.forEach(({ node }) => {
let component = path.resolve('src/templates/testimonial.js')
const component = path.resolve('src/templates/testimonial.js');
createPage({
path: node.frontmatter.path,
component,
context: {
id: node.id,
},
})
})
resolve()
})
)
/* eslint-enable */
});
});
resolve();
}),
);
});
};
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,12 @@
},
"dependencies": {
"gatsby": "^2.0.33",
"gatsby-image": "^2.0.24",
"gatsby-plugin-sass": "^2.0.7",
"gatsby-source-filesystem": "^2.0.12",
"gatsby-transformer-json": "^2.1.6",
"gatsby-transformer-remark": "^2.1.15",
"node-sass": "^4.11.0",
"react": "^16.5.1",
"react-body-classname": "^1.2.0",
"react-dom": "^16.5.1"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Call.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { StaticQuery } from 'gatsby';
import { StaticQuery, graphql } from 'gatsby';

const Call = (props) => {
console.log('Call', props);
Expand Down
4 changes: 0 additions & 4 deletions src/data/contact.yaml

This file was deleted.

10 changes: 5 additions & 5 deletions src/data/social.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
vimeo: ""
twitter: "https://twitter.com/figuritltd"
instagram: ""
linkedin: "https://www.linkedin.com/in/linda-chesher-81a35618/"
facebook: ""
vimeo: ''
twitter: ''
instagram: ''
linkedin: ''
facebook: ''
2 changes: 1 addition & 1 deletion src/scss/pages/testimonials/_page-testimonials.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.page-testimonials-list {
.page-testimonials {
// background-image: url("../images/undraw_hang_out_h9ud.svg");
background-repeat: no-repeat;
background-size: 115%;
Expand Down

0 comments on commit 8e71360

Please sign in to comment.