mirror of
https://github.com/rowyio/rowy.git
synced 2025-12-29 00:16:39 +01:00
enforce usage of lodash-es
This commit is contained in:
16
package.json
16
package.json
@@ -20,7 +20,6 @@
|
||||
"firebase": "^9.6.10",
|
||||
"firebaseui": "^6.0.1",
|
||||
"jotai": "^1.6.4",
|
||||
"lodash": "^4.17.21",
|
||||
"lodash-es": "^4.17.21",
|
||||
"notistack": "^2.0.4",
|
||||
"react": "^18.0.0",
|
||||
@@ -66,6 +65,20 @@
|
||||
"allowSameFolder": true
|
||||
}
|
||||
],
|
||||
"no-restricted-imports": [
|
||||
"error",
|
||||
{
|
||||
"patterns": [
|
||||
{
|
||||
"group": [
|
||||
"lodash",
|
||||
"lodash/*"
|
||||
],
|
||||
"message": "Use lodash-es instead"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"tsdoc/syntax": "warn"
|
||||
}
|
||||
},
|
||||
@@ -92,7 +105,6 @@
|
||||
"@testing-library/user-event": "^14.0.4",
|
||||
"@types/dompurify": "^2.3.3",
|
||||
"@types/jest": "^27.4.1",
|
||||
"@types/lodash": "^4.14.181",
|
||||
"@types/lodash-es": "^4.17.6",
|
||||
"@types/node": "^17.0.23",
|
||||
"@types/react": "^18.0.5",
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import _mapValues from "lodash/mapValues";
|
||||
import { mapValues } from "lodash-es";
|
||||
import meta from "@root/package.json";
|
||||
|
||||
export const EXTERNAL_LINKS = {
|
||||
@@ -51,7 +51,7 @@ const WIKI_PATHS = {
|
||||
extensionsTwilioMessage: "/extensions/twilio-message",
|
||||
webhooks: "/webhooks",
|
||||
};
|
||||
export const WIKI_LINKS = _mapValues(
|
||||
export const WIKI_LINKS = mapValues(
|
||||
WIKI_PATHS,
|
||||
(path) => EXTERNAL_LINKS.docs + path
|
||||
);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { createTheme, ThemeOptions } from "@mui/material/styles";
|
||||
import _merge from "lodash/merge";
|
||||
import { merge } from "lodash-es";
|
||||
|
||||
import { typography } from "@src/theme/typography";
|
||||
import { colorsLight, colorsDark } from "@src/theme/colors";
|
||||
@@ -7,7 +7,7 @@ import { components } from "@src/theme/components";
|
||||
|
||||
export const customizableLightTheme = (customization: ThemeOptions) => {
|
||||
const customizedLightThemeBase = createTheme(
|
||||
_merge(
|
||||
merge(
|
||||
{},
|
||||
typography((customization?.typography as any) ?? {}),
|
||||
colorsLight((customization?.palette?.primary as any)?.main)
|
||||
@@ -15,7 +15,7 @@ export const customizableLightTheme = (customization: ThemeOptions) => {
|
||||
);
|
||||
|
||||
return createTheme(
|
||||
_merge(
|
||||
merge(
|
||||
{},
|
||||
customizedLightThemeBase,
|
||||
components(customizedLightThemeBase),
|
||||
@@ -26,7 +26,7 @@ export const customizableLightTheme = (customization: ThemeOptions) => {
|
||||
|
||||
export const customizableDarkTheme = (customization: ThemeOptions) => {
|
||||
const customizedDarkThemeBase = createTheme(
|
||||
_merge(
|
||||
merge(
|
||||
{},
|
||||
typography((customization?.typography as any) ?? {}),
|
||||
colorsDark(
|
||||
@@ -37,7 +37,7 @@ export const customizableDarkTheme = (customization: ThemeOptions) => {
|
||||
);
|
||||
|
||||
return createTheme(
|
||||
_merge(
|
||||
merge(
|
||||
{},
|
||||
customizedDarkThemeBase,
|
||||
components(customizedDarkThemeBase),
|
||||
|
||||
@@ -3510,7 +3510,7 @@
|
||||
dependencies:
|
||||
"@types/lodash" "*"
|
||||
|
||||
"@types/lodash@*", "@types/lodash@^4.14.181":
|
||||
"@types/lodash@*":
|
||||
version "4.14.181"
|
||||
resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.181.tgz#d1d3740c379fda17ab175165ba04e2d03389385d"
|
||||
integrity sha512-n3tyKthHJbkiWhDZs3DkhkCzt2MexYHXlX0td5iMplyfwketaOeKboEVBqzceH7juqvEg3q5oUoBFxSLu7zFag==
|
||||
|
||||
Reference in New Issue
Block a user