How to use the rmw-shell/lib/utils/localeTools function in rmw-shell

To help you get started, we’ve selected a few rmw-shell examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github TarikHuber / react-most-wanted / src / pages / LandingPage / LandingPage.js View on Github external
},
  bullet: {
    display: 'inline-block',
    margin: '0 2px',
    transform: 'scale(0.8)',
  },
  cardTitle: {
    marginBottom: 16,
    fontSize: 14,
  },
  pos: {
    marginBottom: 12,
  },
})

const match = parseLanguages(['en', 'es', 'bs', 'ru', 'de'], 'en')

// eslint-disable-next-line react/prop-types
const LandingPage = ({ classes, history, theme }) => {
  const messages = messageSources[match]

  const isAuthorised = () => {
    try {
      const key = Object.keys(localStorage).find(e => e.match(/persist:root/))
      const data = JSON.parse(localStorage.getItem(key))
      const auth = JSON.parse(data.auth)

      return auth && auth.isAuthorised
    } catch (ex) {
      return false
    }
  }
github TarikHuber / react-most-wanted / packages / cra-template-rmw / template / src / config / config.js View on Github external
'google.com',
    'facebook.com',
    'twitter.com',
    'github.com',
    'password',
    'phone',
  ],
  googleMaps: {
    apiKey: 'AIzaSyByMSTTLt1Mf_4K1J9necAbw2NPDu2WD7g',
  },
  initial_state: {
    themeSource: {
      isNightModeOn: true,
      source: 'light',
    },
    locale: parseLanguages(['en', 'bs', 'es', 'ru', 'de'], 'en'),
  },
  drawer_width: 256,
  locales,
  themes,
  grants,
  routes,
  getMenuItems,
  firebaseLoad: () => import('./firebase'),
  landingPage: LPAsync,
}

export default config
github TarikHuber / react-most-wanted / src / config / config.js View on Github external
appId: '1:70650394824:web:7cd3113c37741efc',
  },
  firebase_providers: [
    'google.com',
    'facebook.com',
    'twitter.com',
    'github.com',
    'password',
    'phone',
  ],
  initial_state: {
    themeSource: {
      isNightModeOn: true,
      source: 'light',
    },
    locale: parseLanguages(['en', 'bs', 'es', 'ru', 'de'], 'en'),
  },
  drawer_width: 256,
  locales,
  themes,
  grants,
  routes,
  getMenuItems,
  firebaseLoad: () => import('./firebase'),
  landingPage: LPAsync,
}

export default config