Skip to content

Commit

Permalink
Added styleling and applied rules
Browse files Browse the repository at this point in the history
Fixed issue where now created audit
Added editorconfig and applied rules
Updated eslitrc
Updated todos
  • Loading branch information
Marvin Heilemann committed Jan 21, 2020
1 parent 360cb31 commit 27a7a3b
Show file tree
Hide file tree
Showing 45 changed files with 1,418 additions and 256 deletions.
2 changes: 1 addition & 1 deletion .browserslistrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
last 1 version
> 1% in DE
> 1% in DE
16 changes: 16 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# EditorConfig is awesome: https://EditorConfig.org

root = true

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

[Makefile]
indent_style = tab

[*.json]
insert_final_newline = false
File renamed without changes.
2 changes: 1 addition & 1 deletion .nowignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
.github
.github
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
lts/*
lts/*
File renamed without changes.
10 changes: 10 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"extends": [
"stylelint-config-recommended-scss",
"stylelint-prettier/recommended",
"stylelint-config-property-sort-order-smacss"
],
"rules": {
"no-descending-specificity": null
}
}
5 changes: 5 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
{
"css.validate": false,
"scss.validate": false,
"editor.codeActionsOnSave": {
"source.fixAll": true
},
"todo-tree.filtering.excludeGlobs": [
"**/*.md",
],
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ start:
logs:
docker logs marvin-nginx

restart: restart-nginx
# docker-compose restart marvin-xxxx
restart:
docker-compose restart nginx

restart-nginx:
reload-nginx:
docker exec marvin-nginx /usr/share/nginx-reload.sh

newcert:
Expand All @@ -44,4 +44,4 @@ create-dirs:
mkdir -p docker/nginx/certs

setup: create-env create-dirs
@echo Success!
@echo Success!
29 changes: 15 additions & 14 deletions TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
- [x] replace package.json with version.txt to reduce size
- [x] add custom slug to all pages
- [x] test `postcss-easing-gradients` with Scss loaded in `/src`
- [ ] add md table of contents
- [x] ~~add schema generator~~
- [x] new start page: https://labs.semplice.com/s5-vertical-grid
- [x] test purgecss with classes from Markdown files
Expand All @@ -30,16 +29,18 @@
- [x] always use latest NGINX image
- [x] test prod build locally with SSL and brotli compression
- [x] weird lighter background underneath the footer (backdrop-filter issue)
- [ ] setup siteUrl as env var to pass to build process so lighthouse will get
- [x] setup siteUrl as env var to pass to build process so lighthouse will get
the correct canonical url
- [ ] use gatsby images everywhere (homepage for file savings)
- [ ] setup scss linter
- [ ] setup smacss to apply css sort order
- [x] remove bundle analyzer from prod builds in NOW
- [x] setup scss linter
- [x] setup smacss to apply css sort order
- [x] fix issue with node env version in prod build
- [ ] use gatsby images everywhere (homepage for file savings)
- [ ] fix issue with header on prod build
- [ ] MDX pages are not using remark images plugin
- [ ] add md table of contents
- [ ] new image for start: me while coding
- [ ] new image for start: me while writing
- [ ] MDX pages are not using remark images plugin
- [x] put scss theme stuff in own mixin for compat.
- [x] Add footer with: version, social-media, imprint, changelog, copyright
notice
Expand All @@ -49,12 +50,12 @@
- [x] analyze via bundlephobia
- [x] add github bots to auto update dependencies
- [x] add lighthouse from M8FINDER project
- [ ] update lighthouse audit
- [ ] save HTML
- [ ] save JSON
- [ ] save Screenshot for mobile and desktop
- [ ] open only desktop
- [ ] script to open mobile
- [x] update lighthouse audit
- [x] save HTML
- [x] save JSON
- [x] save Screenshot for mobile and desktop
- [x] open only desktop
- [x] script to open mobile
- [ ] open summary view by default
- [x] Make text justified
- [ ] add scroll to top
Expand All @@ -73,11 +74,11 @@
- [ ] Update images
- [ ] Upload some photos (best off's)
- [ ] Setup SimpleAnalytics or something similar
- [ ] check pages with Firefox Axe
- [x] check pages with Firefox Axe
- [ ] check all pages with screen reader
- [ ] check all pages with reduced motion
- [ ] check all pages with reduced transparency
- [ ] PWA: add service worker for offline usage
- [x] PWA: add service worker for offline usage (`gatsby-plugin-offline`)
- [x] ~~add tests?!~~
- [x] ~~move from bash script to [Nim][2]~~
- [ ] (auto) check markdown for ["Vary sentence length"][3]
Expand Down
33 changes: 21 additions & 12 deletions gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,16 @@ require('dotenv').config({
path: `.env.build`,
})

const { yellow, blue } = require('kleur')
const { yellow, blue, bold } = require('kleur')
const { getVersion, transformVersion } = require('./utils/version')
const { activeEnv, isDev } = require('./utils/environment')
const { activeEnv, isAudit } = require('./utils/environment')
const commonRemark = require('./gatsby/config/commonRemark')
const siteMetadata = require('./metadata')

console.log(bold(siteMetadata.siteTitle))
console.log(`Version: ${blue(getVersion())}`)
console.log(`Environment: ${yellow(activeEnv)}`)
console.log(`Version: ${blue(getVersion())}\n`)
console.log(`Auditing: ${yellow(isAudit)}\n`)

module.exports = {
siteMetadata,
Expand Down Expand Up @@ -170,6 +172,20 @@ module.exports = {
icon: './static/favicon.svg',
},
},
{
resolve: `gatsby-plugin-offline`,
options: {
precachePages: [
`/about/`,
`/imprint/`,
`/credits/`,
`/changelog/`,
`/projects/*`,
`/photography/*`,
`/writings/*`,
],
},
},
{
resolve: `gatsby-plugin-humans-txt`,
options: {
Expand Down Expand Up @@ -211,20 +227,13 @@ module.exports = {
},
},
// BUG: https://github.com/angeloashmore/gatsby-plugin-react-axe/issues/6
// {
// resolve: 'gatsby-plugin-react-axe',
// options: {
// showInProduction: false,
// // https://github.com/dequelabs/axe-core/blob/master/doc/API.md#api-name-axeconfigure
// axeOptions: {},
// },
// },
// isDev && 'gatsby-plugin-react-axe',
{
resolve: 'gatsby-plugin-webpack-bundle-analyzer',
options: {
analyzerMode: 'static',
production: true,
disable: isDev,
disable: !isAudit, // only run when doing production builds to perform audits
openAnalyzer: false,
reportFilename: `${__dirname}/reports/v${transformVersion(
getVersion(),
Expand Down
4 changes: 2 additions & 2 deletions metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ module.exports = {
siteTitleShort: 'M/D',
siteAuthor: `Marvin Heilemann`,
siteDescription: `Projects Marvin Heilemann has been working on now and in the past.`,
siteUrl: 'https://marvin.digital',
siteLanguage: 'en',
siteKeywords: [
'muuvmuuv',
'portfolio',
Expand All @@ -13,6 +11,8 @@ module.exports = {
'writings',
'photography',
],
siteUrl: process.env.SITE_URL || 'https://marvin.digital',
siteLanguage: 'en',
menu: [
{
name: 'About',
Expand Down
Loading

0 comments on commit 27a7a3b

Please sign in to comment.