- App.tsx: full navigation (Auth stack + Main tabs with 5 screens) - Auth: LoginScreen, RegisterScreen, ForgotPasswordScreen - HomeScreen: dashboard with IoT metrics, weather widget, alerts, quick actions, sensors - MapScreen: interactive map with layer toggles (6 layers) - MarketplaceScreen: categories (6), products (5), search - ChatScreen: AI chat with quick prompts (4), bot responses - ProfileScreen: user info, stats, menu (9 items), logout - AlertsScreen: alert list with severity, acknowledge - SensorsScreen: sensor list with type filters (6 types), search - ZonesScreen: zone cards with stats - SettingsScreen: language picker (FR/EN/ES/DE), privacy, about - Stores: iotStore (sensors, zones, alerts), notificationStore, uiStore + i18n - Hooks: useSensors, useAlerts, useNotifications, useLocation - Components: Card, Button, LoadingSpinner, ErrorBoundary, Header - Services: iotService, notificationService (with axios API client) - Utils: formatters (temp, AQI, noise, dates), validators (email, password, IBAN) - Theme: colors.ts with full design system (Blue Ocean palette) - Ditto: fixed MongoDB connection, new JWT secrets, official gateway image
70 lines
2.0 KiB
JavaScript
70 lines
2.0 KiB
JavaScript
"use strict";
|
|
|
|
Object.defineProperty(exports, "__esModule", {
|
|
value: true
|
|
});
|
|
exports.getMetroBundleOptions = getMetroBundleOptions;
|
|
function _cliTools() {
|
|
const data = require("@react-native-community/cli-tools");
|
|
_cliTools = function () {
|
|
return data;
|
|
};
|
|
return data;
|
|
}
|
|
function _fs() {
|
|
const data = _interopRequireDefault(require("fs"));
|
|
_fs = function () {
|
|
return data;
|
|
};
|
|
return data;
|
|
}
|
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
function getMetroBundleOptions(downloadedProfileFilePath, host) {
|
|
let options = {
|
|
platform: 'android',
|
|
dev: true,
|
|
minify: false,
|
|
host
|
|
};
|
|
try {
|
|
const contents = JSON.parse(_fs().default.readFileSync(downloadedProfileFilePath, {
|
|
encoding: 'utf8'
|
|
}));
|
|
const matchBundleUrl = /^.*\((.*index\.bundle.*)\)/;
|
|
let containsExpoDevMenu = false;
|
|
let hadMatch = false;
|
|
for (const frame of Object.values(contents.stackFrames)) {
|
|
if (frame.name.includes('EXDevMenuApp')) {
|
|
containsExpoDevMenu = true;
|
|
}
|
|
const match = matchBundleUrl.exec(frame.name);
|
|
if (match) {
|
|
const parsed = new URL(match[1]);
|
|
const platform = parsed.searchParams.get('platform'),
|
|
dev = parsed.searchParams.get('dev'),
|
|
minify = parsed.searchParams.get('minify');
|
|
if (platform) {
|
|
options.platform = platform;
|
|
}
|
|
if (dev) {
|
|
options.dev = dev === 'true';
|
|
}
|
|
if (minify) {
|
|
options.minify = minify === 'true';
|
|
}
|
|
hadMatch = true;
|
|
break;
|
|
}
|
|
}
|
|
if (containsExpoDevMenu && !hadMatch) {
|
|
_cliTools().logger.warn(`Found references to the Expo Dev Menu in your profiling sample.
|
|
You might have accidentally recorded the Expo Dev Menu instead of your own application.
|
|
To work around this, please reload your app twice before starting a profiler recording.`);
|
|
}
|
|
} catch (e) {
|
|
throw e;
|
|
}
|
|
return options;
|
|
}
|
|
|
|
//# sourceMappingURL=metroBundleOptions.ts.map
|