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

182
Vistas
How to insert/update Immutable.Map of Immutable.Map in JavaScript?

I have a nested Immutable.Map of Immutable.Map type defined as follows:

export type Data = Immutable.Map<string, Immutable.Map<string, string>>;

const nested : Data = Immutable.Map();

Data in the nested should look like this:

{
  'a': {
    'a1': 'value1',
    'a2': 'value2',
  },
  'b': {
    'b1': 'value1',
    'b2': 'value2',
  },
...
}

How should I insert/update a value for the nested variable (assume I have input like {'a', 'a1', 'value1'})? I know I can do checks and create the second immutable map if it's null, but is there an easier way to do that?

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