GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - scality/Guidelines: Provide the basic common guidelines for Scality JS projects

BranchesTags
Open more actions menu

Latest commit

 

History

187 Commits
187 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
bin
bin
 
 
tests
tests
 
 
.editorconfig
.editorconfig
 
 
.gitignore
.gitignore
 
 
CONTRIBUTING.md
CONTRIBUTING.md
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
TESTING.md
TESTING.md
 
 
domain_vs_promises.md
domain_vs_promises.md
 
 
eslint.config.cjs
eslint.config.cjs
 
 
index.js
index.js
 
 
package.json
package.json
 
 
prettier.config.cjs
prettier.config.cjs
 
 
yarn.lock
yarn.lock
 
 

Repository files navigation

Guidelines

This project:

  • Defines and explains the coding style and workflow for the S3 project. See CONTRIBUTING.md for details.

  • Provides an eslint-config-scality package that can be added as a dependency in other projects. That way, coding style can automatically be checked using eslint.

Prettier baseline

This repository also provides a baseline Prettier configuration for Scality object repositories: 4-space JavaScript/TypeScript indentation, 120-character line length, single quotes, semicolons, trailing commas, and quoteProps: 'consistent'.

The configuration lives in prettier.config.cjs.

To use it in a project:

  1. Install Prettier in the project:

    yarn add --dev prettier
    # or
    npm install --save-dev prettier
  2. Copy or extend the configuration:

    // prettier.config.cjs
    module.exports = require('eslint-config-scality/prettier.config.cjs');
  3. Add convenience scripts:

    {
        "scripts": {
            "format": "prettier --write .",
            "format:check": "prettier --check .",
            "prettier:diff": "scality-prettier-diff"
        }
    }

Projects may override options locally (for example tabWidth or printWidth) if they have strong legacy constraints, but this configuration is intended to be the default Scality baseline for new or reformatted Node.js codebases. YAML/JSON/Markdown files default to a 2-space indentation and Markdown prose is left un-reflowed by default (proseWrap: 'preserve'), to avoid noisy diffs in existing documentation.

For pull request checks or local review of changed files, this package exposes the scality-prettier-diff script. It runs Prettier on files returned by git diff --name-only --diff-filter=ACMRT, defaults to --check, and forwards remaining arguments to git diff.

Examples:

yarn run prettier:diff
yarn run prettier:diff --check HEAD~1..HEAD
yarn run prettier:diff --write --cached

Contributing

  • See CONTRIBUTING.md for contribution guidelines and coding standards.
  • See TESTING.md for details on running the linters and tests in this repo.

About

Provide the basic common guidelines for Scality JS projects

Resources

Readme
Apache-2.0 license

Contributing

Contributing
Activity
Custom properties

Stars

2 stars

Watchers

49 watching

Forks

1 fork
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.