Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LINT-75(feedback): Wrong import order for aliased layers #81

Merged
merged 2 commits into from
Jan 31, 2022

Conversation

Krakazybik
Copy link
Member

@Krakazybik Krakazybik commented Jan 31, 2022

Description

Добавлена поддержка альясов (~,@) для импортов.

References

#80

Checklist

  • Description added
  • Self-reviewed
  • CI pass

@Krakazybik Krakazybik requested a review from azinit January 31, 2022 19:11
@Krakazybik Krakazybik self-assigned this Jan 31, 2022
@Krakazybik Krakazybik added the bug Something isn't working label Jan 31, 2022
Comment on lines 34 to 42
import axios from "axios"; // 1) external libs
import { Zero } from "@widget/zero"; // Layers: widget - Alias
import { Header } from "widgets/header"; // 2.1) Layers: widgets
import { LoginForm } from "features/login-form"; // 2.2) Layers: features
import { authModel } from "entities/auth"; // 2.3) Layers: entities
import { One } from "@entities/one"; // Layers: entities - Alias
import { Two } from "@entities/two"; // Layers: entities - Alias
import { Cart } from "@/entities/cart"; // Layers: entities - Alias
import { Input } from "~/shared/ui"; // Layers: shared - Alias
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Топ, что разнообразил форматы импортов)

@@ -10,7 +10,7 @@ module.exports = {
{
pathGroups: layersLib.FS_LAYERS.map(
(layer) => ({
pattern: `**/?(@|~)${layer}/**` ,
pattern: `**/?(*)${layer}/**` ,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Спс что поменял)

@azinit azinit merged commit fe100c7 into master Jan 31, 2022
@azinit azinit deleted the bugfix/LINT-75-wrong-import-order-for-aliases branch January 31, 2022 20:29
@Krakazybik Krakazybik linked an issue Jan 31, 2022 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

LINT: (Feedback) Incorrect imports order in aliased layers
2 participants