Package Exports
- prettier-config-landr
- prettier-config-landr/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (prettier-config-landr) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
prettier-config-landr
This package exposes the Prettier configuration used for LANDR projects.
Installation
Install prettier-config-landr
and prettier
as a dev dependency to your project.
# Using npm
npm install prettier prettier-config-landr --save-dev
# Using yarn
yarn add prettier prettier-config-landr --dev
Then in a .prettierrc.js
file, add the following:
module.exports = require('prettier-config-landr');
Overriding settings
To overwrite some of the settings provided by prettier-config-landr
the .prettierrc.js
file should be setup as follows:
// Example of using prettier-config-landr while changing the tab width for .scss files to 2 spaces
const defaultConfig = require('prettier-config-landr');
module.exports = {
...defaultConfig,
overrides: [
...defaultConfig.overrides,
{
files: '*.scss',
options: {
tabWidth: 2,
},
},
],
};