npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@aikon/aikon-configs

v1.0.5

Published

## Shared AIKON configuration files

Downloads

81

Readme

Aikon Config library

Shared AIKON configuration files

Reusable ESLint, Prettier, Typescript, and other config files

How to use

First step: Isntall

First add the package:

yarn add -D @aikon/aikon-config jest

Attention: @aikon/aikon-config must always be added as a devDependencies. If added as dependencies you may have build errors.

Attention 2: @aikon/aikon-config will install prittier, lint and all necessary plugins. Therefore the project must not install any additional packages. Only @aikon/aikon-config is needed

Why install jest?

The lint settings are ready to work with jest (which is being implemented little by little in the libs). So, if you don't install jest, when trying to run lint some errors will happen.

Second step: Config

Inside the project you must create the prittier and lint configuration files.

For lint you must create a file named .eslintrc.js:

// .eslintrc.js
module.exports = require("@aikon/aikon-configs/eslint-config-aikon");
// OR (if you want to use this on react projects)
module.exports = require("@aikon/aikon-configs/eslint-config-react-aikon");

For prettier you must create a file named .prettierrc.js:

// .prettierrc.js
module.exports = require("@aikon/aikon-configs/prettier-config-aikon");

Attention: Both lint and prettier have several naming options for configuration files. Make sure there are no other files as this can lead to miss function/erros.

Use inside this monorepo.

When we are using this package inside some other package inside this monorepo the installation is a little different. In these cases we should not use yarn, just add "@aikon/aikon-configs": "*" as to devDependencies, and also add jest. But attention, this is only valid for packages inside this monorepo.

Common Mistakes

If you're having trouble running lint or prittier, here are some common issues.

Incompatible versions of eslint.

If the lib already had a version of eslint installed and when installing @aikon/aikon-configs you just deleted the eslint (and its plugins) from the package.json file you may end up with incompatible versions of eslint.

The quickest way to fix this error is to verify that no eslint (and no plugins) are in package.json nor package-lock.json or yarn.lock. If this is the case, you can delete the eslint and its plugins from "the lock file", and then run yarn install (Usually deleting the entire lock-file solves the problem but beware that it is not possible to do this in all projects).

Error with jest.

As mentioned in the installation session, lint is already configured to work correctly with jest. So, if you're seeing this error, it's possible you haven't installed jest. To fix just run yarn add -D jest.

It is not necessary to have any tests created, only the package must be installed.

Build erros

If after adding @aikon/aikon-configs you are having errors in the build, check if it is in dependencies. If it is, move it to devDependencies. @aikon/aikon-configs it should only be a devDependencies never an dependencies.