package.configs.nanos.eslint.imports.order.js Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of neeto-commons-frontend Show documentation
Show all versions of neeto-commons-frontend Show documentation
A package encapsulating common code across neeto projects including initializers, utility functions, common components and hooks and so on.
const { assocPath } = require("ramda");
const {
buildPathGroupsBasedOnWebpackAliases,
} = require("../../../eslint/helpers");
const commonConfig = require("../../../eslint/imports/order");
const pathGroups = buildPathGroupsBasedOnWebpackAliases({
customAliasPath: "resolve.js",
commonAliasPath:
"node_modules/@bigbinary/neeto-commons-frontend/configs/nanos/webpack/resolve.js",
});
const pathGroupForKeepingReactImportsAtTop = {
pattern: "react+(-native|)",
group: "external",
position: "before",
};
pathGroups.push(pathGroupForKeepingReactImportsAtTop);
module.exports = assocPath(
["rules", "import/order", 1, "pathGroups"],
pathGroups,
commonConfig
);