eslint-plugin-import icon indicating copy to clipboard operation
eslint-plugin-import copied to clipboard

What is the signifance of each group name? what do they mean?

Open airtonix opened this issue 5 years ago • 2 comments

Some of the words might be obvious to seasoned developers, but for others it's not so obvious.

Here's my understanding :

src/App/AppContainer.js where ~ is an alias to src/**

import fs from 'fs' // builtin
import path from 'path' // builtin

import React, { Component } from 'react' // external
import '@babel/register' // external

import { MagicalPonyContainer } from '~/unicorns/MagicalPonyContainer' // internal ?

import { TrollFaceContainer } from '../Components/TrollFaceContainer' // parent ?

import 'omgfacerolllmao' // unknown ?

import './something/index.js' // index ? 

import { App } from './App' // sibling ?
import './App.scss' // sibling ?

// no idea what object would be.

This could all be wrong, or it's completely right. In any case I feel it's worth illustrating this in the readme.

I'm happy to make a PR on this, but perhaps some guidance and input from others with a better understanding would be great.

airtonix avatar Oct 22 '20 00:10 airtonix

Even I would like to know whether the mentioned understanding of groups is correct? Also it would be good to have eslint import plugin config example with mono repo setup

aqumus avatar Dec 03 '20 08:12 aqumus

Your understanding seems correct to me (altho omgfacerolllmao would be "external" if it resolved).

PRs to improve the docs are always appreciated.

ljharb avatar Dec 03 '20 19:12 ljharb