Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

171
Vistas
Import a JSON or declare an array

I have a huge object with ~5000 keys. Just key and value, both strings, like this:

{
  "key1": "value1",
  "key2": "value2",
  ...
}

Currently I import this as a JSON

import dataset from 'dataset.json'

And looking at the result, I noticed that the bundled javascript has this JSON inline and uses JSON.parse. I was wondering if I use plain JavaScript and export like a variable would be better, thoughts?

For example, if it was in Python, I know that is more efficient to parse JSON than parse Python code and I will use JSON instead.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda