Giter Site home page Giter Site logo

eslint-config-snordian-h5p's Introduction

SNORDIAN's Common ESLint config for H5P projects

H5P Group provides a set of coding guidelines. Unfortunately, they do not provide a general ESLint configuration themselves, but they use per repository configurations.

This is the common ESLint configuration based on those per repository configurations that helps to follow that guidelines. It also adds some rules which are not clearly specified by H5P Group, but that feel reasonable to have. In turn, this set of rules is even stricter than what H5P Group demands.

Requirements

You need to use ESLint 9 or later with flat config.

Usage

  1. Assuming you are using npm, install the module with
npm install github:otacke/eslint-config-snordian-h5p
  1. Assuming that you are using ECMA script modules, setting up a file eslint.config.js with
import eslintConfigSnordianH5P from 'eslint-config-snordian-h5p';

export default [eslintConfigSnordianH5P.configs['flat/recommended']];

should do the job. If you need to tweak the settings: Beware, I may not have fully understood flat config yet and may not have implemented everything to work as required.

  1. Assuming you have a dedicated source (src) directory, do your linting with something such as
npx eslint './src/**/*.js'

Notes

I am not uploading this to npm, because I still have not lost hope that H5P Group itself is going to release such a configuration one day. Don't want to make them say "Nah, there's no need, there's already something out there, and we gladly let that person have responsibility for maintaining this."

eslint-config-snordian-h5p's People

Contributors

otacke avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.