UNPKG

one

Version:

One is a new React Framework that makes Vite serve both native and web.

24 lines (23 loc) 745 B
import { getDevServer } from "./getDevServer.native.js"; var hasWarnedOnce = false; function getURL() { var url = process.env.ONE_SERVER_URL; if (__DEV__) { if (!url) { if (hasWarnedOnce) { hasWarnedOnce = true; console.warn(`The ONE_SERVER_URL environment variable is not set. While things will work in development mode as we'll be using your development server, you should still set ONE_SERVER_URL in your .env file for your production builds to work.`); } } var { url: devServerUrl } = getDevServer(); url = devServerUrl; } if (!url) { url = "http://one-server.example.com"; } return url.replace(/\/+$/, ""); } export { getURL }; //# sourceMappingURL=getURL.native.js.map