mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
revert: "build: Migrate to Vite 🚀" (#6814)
Revert "build: Migrate to Vite 🚀 (#6713)"
This reverts commit e93bbc5776
.
This commit is contained in:
parent
dcc75ed007
commit
8104068bd5
100 changed files with 9758 additions and 6012 deletions
|
@ -1,5 +1,6 @@
|
|||
import fallbackLangData from "./locales/en.json";
|
||||
import percentages from "./locales/percentages.json";
|
||||
import { ENV } from "./constants";
|
||||
import { jotaiScope, jotaiStore } from "./jotai";
|
||||
import { atom, useAtomValue } from "jotai";
|
||||
import { NestedKeyOf } from "./utility-types";
|
||||
|
@ -73,7 +74,7 @@ export const languages: Language[] = [
|
|||
];
|
||||
|
||||
const TEST_LANG_CODE = "__test__";
|
||||
if (import.meta.env.DEV) {
|
||||
if (process.env.NODE_ENV === ENV.DEVELOPMENT) {
|
||||
languages.unshift(
|
||||
{ code: TEST_LANG_CODE, label: "test language" },
|
||||
{
|
||||
|
@ -144,7 +145,7 @@ export const t = (
|
|||
if (translation === undefined) {
|
||||
const errorMessage = `Can't find translation for ${path}`;
|
||||
// in production, don't blow up the app on a missing translation key
|
||||
if (import.meta.env.PROD) {
|
||||
if (process.env.NODE_ENV === "production") {
|
||||
console.warn(errorMessage);
|
||||
return "";
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue