1
0
mirror of https://github.com/kremalicious/portfolio.git synced 2024-12-22 17:23:22 +01:00

lint fixes

This commit is contained in:
Matthias Kretschmann 2018-05-22 22:51:41 +02:00
parent 3cb9319a93
commit 34ef21cf52
Signed by: m
GPG Key ID: 606EEEF3C479A91F
7 changed files with 39 additions and 36 deletions

View File

@ -5,7 +5,7 @@
"plugin:react/recommended", "plugin:react/recommended",
"plugin:prettier/recommended" "plugin:prettier/recommended"
], ],
"plugins": ["react", "graphql", "prettier", "compat"], "plugins": ["react", "graphql", "prettier"],
"parserOptions": { "parserOptions": {
"sourceType": "module", "sourceType": "module",
"ecmaFeatures": { "ecmaFeatures": {
@ -25,7 +25,6 @@
"quotes": ["error", "single"], "quotes": ["error", "single"],
"semi": ["error", "never"], "semi": ["error", "never"],
"object-curly-spacing": ["error", "always"], "object-curly-spacing": ["error", "always"],
"prettier/prettier": "error", "prettier/prettier": "error"
"compat/compat": "error"
} }
} }

View File

@ -6,7 +6,7 @@ const { url, googleanalytics, matomoUrl, matomoSite } = meta
module.exports = { module.exports = {
siteMetadata: { siteMetadata: {
siteUrl: `${url}`, siteUrl: `${url}`
}, },
plugins: [ plugins: [
'gatsby-plugin-react-next', 'gatsby-plugin-react-next',
@ -24,31 +24,31 @@ module.exports = {
resolve: 'gatsby-source-filesystem', resolve: 'gatsby-source-filesystem',
options: { options: {
name: 'pkg', name: 'pkg',
path: path.join(__dirname, 'package.json'), path: path.join(__dirname, 'package.json')
}, }
}, }
], ]
}, }
}, },
{ {
resolve: 'gatsby-plugin-sass', resolve: 'gatsby-plugin-sass',
options: { options: {
includePaths: [`${__dirname}/node_modules`, `${__dirname}/src/styles`], includePaths: [`${__dirname}/node_modules`, `${__dirname}/src/styles`]
}, }
}, },
{ {
resolve: 'gatsby-source-filesystem', resolve: 'gatsby-source-filesystem',
options: { options: {
name: 'data', name: 'data',
path: path.join(__dirname, 'data'), path: path.join(__dirname, 'data')
}, }
}, },
{ {
resolve: 'gatsby-source-filesystem', resolve: 'gatsby-source-filesystem',
options: { options: {
name: 'images', name: 'images',
path: path.join(__dirname, 'src', 'images'), path: path.join(__dirname, 'src', 'images')
}, }
}, },
{ {
resolve: 'gatsby-plugin-google-analytics', resolve: 'gatsby-plugin-google-analytics',
@ -56,8 +56,8 @@ module.exports = {
trackingId: `${googleanalytics}`, trackingId: `${googleanalytics}`,
head: false, head: false,
anonymize: true, anonymize: true,
respectDNT: true, respectDNT: true
}, }
}, },
{ {
resolve: 'gatsby-plugin-matomo', resolve: 'gatsby-plugin-matomo',
@ -65,16 +65,16 @@ module.exports = {
siteId: `${matomoSite}`, siteId: `${matomoSite}`,
siteUrl: `${url}`, siteUrl: `${url}`,
matomoUrl: `${matomoUrl}`, matomoUrl: `${matomoUrl}`,
localScript: '/piwik.js', localScript: '/piwik.js'
}, }
}, },
{ {
resolve: 'gatsby-plugin-svgr', resolve: 'gatsby-plugin-svgr',
options: { options: {
icon: false, icon: false,
viewBox: true, viewBox: true
// see https://github.com/smooth-code/svgr for a list of all options // see https://github.com/smooth-code/svgr for a list of all options
}, }
}, },
{ {
resolve: 'gatsby-plugin-favicon', resolve: 'gatsby-plugin-favicon',
@ -90,9 +90,9 @@ module.exports = {
firefox: true, firefox: true,
twitter: false, twitter: false,
yandex: true, yandex: true,
windows: true, windows: true
}, }
}, }
}, }
], ]
} }

View File

@ -7,7 +7,7 @@ exports.modifyWebpackConfig = ({ config, stage }) => {
if (stage === 'build-html') { if (stage === 'build-html') {
config.loader('null', { config.loader('null', {
test: /intersection-observer/, test: /intersection-observer/,
loader: 'null-loader', loader: 'null-loader'
}) })
} }
} }
@ -82,8 +82,8 @@ exports.createPages = ({ boundActionCreators, graphql }) => {
context: { context: {
slug, slug,
previous, previous,
next, next
}, }
}) })
} }
) )

View File

@ -51,7 +51,6 @@
"eslint": "^4.19.1", "eslint": "^4.19.1",
"eslint-config-prettier": "^2.9.0", "eslint-config-prettier": "^2.9.0",
"eslint-loader": "^2.0.0", "eslint-loader": "^2.0.0",
"eslint-plugin-compat": "^2.2.0",
"eslint-plugin-graphql": "^2.1.1", "eslint-plugin-graphql": "^2.1.1",
"eslint-plugin-prettier": "^2.6.0", "eslint-plugin-prettier": "^2.6.0",
"eslint-plugin-react": "^7.8.2", "eslint-plugin-react": "^7.8.2",

View File

@ -35,8 +35,8 @@ $breakpoint-project-nav: 45rem;
} }
} }
/* stylelint-disable no-descending-specificity */
&:last-child { &:last-child {
// stylelint-disable-line
margin-left: $spacer / 2; margin-left: $spacer / 2;
&:hover, &:hover,
@ -44,6 +44,7 @@ $breakpoint-project-nav: 45rem;
transform: translate3d(.5rem, 0, 0); transform: translate3d(.5rem, 0, 0);
} }
} }
/* stylelint-enable no-descending-specificity */
@media (min-width: $breakpoint-project-nav) { @media (min-width: $breakpoint-project-nav) {
flex-basis: 33%; flex-basis: 33%;

View File

@ -1,3 +1,5 @@
/* eslint-disable no-unused-vars */
/** /**
* vCard Property * vCard Property
* @constructor * @constructor
@ -86,8 +88,7 @@ Property.prototype = {
* @param {String} version * @param {String} version
* @return {String} * @return {String}
*/ */
toString: function(version) { // eslint-disable-line no-unused-vars toString: function(version) {
var propName = var propName =
(this.group ? this.group + '.' : '') + capitalDashCase(this._field) (this.group ? this.group + '.' : '') + capitalDashCase(this._field)
var keys = Object.keys(this) var keys = Object.keys(this)
@ -138,7 +139,7 @@ Property.prototype = {
} }
return data return data
}, }
} }
// Exports // Exports

View File

@ -1,3 +1,5 @@
/* eslint-disable no-unused-vars */
/** /**
* vCard * vCard
* @constructor * @constructor
@ -275,7 +277,8 @@ vCard.prototype = {
* @param {String} charset * @param {String} charset
* @return {String} * @return {String}
*/ */
toString: function(version, charset) { // eslint-disable-line no-unused-vars toString: function(version, charset) {
// eslint-disable-line no-unused-vars
version = version || this.version version = version || this.version
return vCard.format(this, version) return vCard.format(this, version)
}, },
@ -313,7 +316,7 @@ vCard.prototype = {
*/ */
toJSON: function() { toJSON: function() {
return this.toJCard(this.version) return this.toJCard(this.version)
}, }
} }
// Exports // Exports