commonInitialization.tsx 535 B

12345678910111213141516
  1. import 'focus-visible';
  2. import {NODE_ENV, UI_DEV_ENABLE_PROFILING} from 'sentry/constants';
  3. import ConfigStore from 'sentry/stores/configStore';
  4. import {Config} from 'sentry/types';
  5. export function commonInitialization(config: Config) {
  6. if (NODE_ENV === 'development') {
  7. import(/* webpackMode: "eager" */ 'sentry/utils/silence-react-unsafe-warnings');
  8. if (UI_DEV_ENABLE_PROFILING) {
  9. config.sentryConfig.profilesSampleRate = 1.0; // Enable profiling on dev for now.
  10. }
  11. }
  12. ConfigStore.loadInitialData(config);
  13. }