New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

hardhat-prettier

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hardhat-prettier

Hardhat plugin to format your code using Prettier Solidity

latest
Source
npmnpm
Version
0.0.1
Version published
Weekly downloads
50
-15.25%
Maintainers
1
Weekly downloads
 
Created
Source

hardhat-prettier

Use Prettier Solidity to format your code.

What

This plugin lets you automatically format your code using Prettier Solidity and check that it's correctly formatted.

Installation

<A step-by-step guide on how to install the plugin>

npm install hardhat-prettier prettier prettier-plugin-solidity

Import the plugin in your hardhat.config.js:

require("hardhat-prettier");

Or if you are using TypeScript, in your hardhat.config.ts:

import "hardhat-prettier";

Tasks

This plugin adds the format task, that will format and overwrite your Solidity code.

It also overrides the check task, to add checking your code's format as part of the check pipeline.

Configuration

This plugin will use prettier's defaults, but you can configure it by creating a .prettierrc file:

{
  "plugins": ["prettier-plugin-solidity"],
  "singleQuote": true
}

Keywords

ethereum

FAQs

Package last updated on 20 Nov 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts