You've already forked AstralRinth
forked from didirus/AstralRinth
Migrate from staging to default api modrinth. Rollback frontend nuxi prepare
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "@modrinth/app-frontend",
|
"name": "@modrinth/app-frontend",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "0.8.9031",
|
"version": "0.8.904",
|
||||||
"development_build": true,
|
"development_build": true,
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import { globIterate } from "glob";
|
|||||||
import { match as matchLocale } from "@formatjs/intl-localematcher";
|
import { match as matchLocale } from "@formatjs/intl-localematcher";
|
||||||
import { consola } from "consola";
|
import { consola } from "consola";
|
||||||
|
|
||||||
const STAGING_API_URL = "https://staging-api.modrinth.com/v2/";
|
const API_URL = "https://api.modrinth.com/v2/";
|
||||||
|
|
||||||
const preloadedFonts = [
|
const preloadedFonts = [
|
||||||
"inter/Inter-Regular.woff2",
|
"inter/Inter-Regular.woff2",
|
||||||
@@ -433,7 +433,7 @@ export default defineNuxtConfig({
|
|||||||
|
|
||||||
function getApiUrl() {
|
function getApiUrl() {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
return process.env.BROWSER_BASE_URL ?? globalThis.BROWSER_BASE_URL ?? STAGING_API_URL;
|
return process.env.BROWSER_BASE_URL ?? globalThis.BROWSER_BASE_URL ?? API_URL;
|
||||||
}
|
}
|
||||||
|
|
||||||
function isProduction() {
|
function isProduction() {
|
||||||
@@ -457,7 +457,7 @@ function getDomain() {
|
|||||||
return `https://${process.env.HEROKU_APP_NAME}.herokuapp.com`;
|
return `https://${process.env.HEROKU_APP_NAME}.herokuapp.com`;
|
||||||
} else if (process.env.VERCEL_URL) {
|
} else if (process.env.VERCEL_URL) {
|
||||||
return `https://${process.env.VERCEL_URL}`;
|
return `https://${process.env.VERCEL_URL}`;
|
||||||
} else if (getApiUrl() === STAGING_API_URL) {
|
} else if (getApiUrl() === API_URL) {
|
||||||
return "https://staging.modrinth.com";
|
return "https://staging.modrinth.com";
|
||||||
} else {
|
} else {
|
||||||
return "https://modrinth.com";
|
return "https://modrinth.com";
|
||||||
|
|||||||
@@ -7,6 +7,7 @@
|
|||||||
"dev": "nuxi dev",
|
"dev": "nuxi dev",
|
||||||
"generate": "nuxi generate",
|
"generate": "nuxi generate",
|
||||||
"preview": "nuxi preview",
|
"preview": "nuxi preview",
|
||||||
|
"postinstall": "nuxi prepare",
|
||||||
"lint": "eslint . && prettier --check .",
|
"lint": "eslint . && prettier --check .",
|
||||||
"fix": "eslint . --fix && prettier --write .",
|
"fix": "eslint . --fix && prettier --write .",
|
||||||
"intl:extract": "formatjs extract \"{,src/components,src/composables,src/layouts,src/middleware,src/modules,src/pages,src/plugins,src/utils}/**/*.{vue,ts,tsx,js,jsx,mts,cts,mjs,cjs}\" --ignore '**/*.d.ts' --ignore 'node_modules' --out-file src/locales/en-US/index.json --format crowdin --preserve-whitespace"
|
"intl:extract": "formatjs extract \"{,src/components,src/composables,src/layouts,src/middleware,src/modules,src/pages,src/plugins,src/utils}/**/*.{vue,ts,tsx,js,jsx,mts,cts,mjs,cjs}\" --ignore '**/*.d.ts' --ignore 'node_modules' --out-file src/locales/en-US/index.json --format crowdin --preserve-whitespace"
|
||||||
|
|||||||
Reference in New Issue
Block a user