Skip to content

Commit

Permalink
Add the Prettier configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
octogonz committed Jun 9, 2020
1 parent 917c464 commit f7ad5d1
Show file tree
Hide file tree
Showing 2 changed files with 109 additions and 0 deletions.
99 changes: 99 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
#-------------------------------------------------------------------------------------------------------------------
# Keep this section in sync with .gitignore
#-------------------------------------------------------------------------------------------------------------------

# Logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Runtime data
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env

# next.js build output
.next

# OS X temporary files
.DS_Store

# Rush temporary files
common/deploy/
common/temp/
**/.rush/temp/

# Common toolchain intermediate files
temp
lib
lib-amd
lib-es6
dist
*.scss.ts
*.sass.ts

# Visual Studio Code
.vscode

# Remove eventually
package-deps.json

#-------------------------------------------------------------------------------------------------------------------
# Prettier-specific overrides
#-------------------------------------------------------------------------------------------------------------------

# Machine-egnerated files
common/reviews
common/changes
CHANGELOG.*
pnpm-lock.yaml
build-tests/*/etc
dist-dev
dist-prod

# We'll consider enabling this later; Prettier reformats code blocks, which affects end-user content
*.md
10 changes: 10 additions & 0 deletions .prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Documentation for this file: https://prettier.io/docs/en/configuration.html
module.exports = {
// We use a larger print width because Prettier's word-wrapping seems to be tuned
// for plain JavaScript without type annotations
printWidth: 110,
// Microsoft style quotes
singleQuote: true,
// Preserve existing newlines
endOfLine: 'auto',
};

0 comments on commit f7ad5d1

Please sign in to comment.