Proper way to declare JSON object in Typescript

Discussão em 'Angular' iniciado por Per Larsen, Agosto 13, 2025.

  1. Per Larsen

    Per Larsen Guest

    I have the following JSON object in my Angular 2 app and would like to know what is the proper what to declare it in typescript.

    data = [
    {
    'id':1,
    'title':'something'
    'node': [
    {
    'id':1,
    'title':'something'
    'node': []
    }
    ]
    },
    {
    'id':2,
    'title':'something'
    'node': [
    {
    'id':1,
    'title':'something'
    'node': []
    }
    ]
    }
    ]

    Continue reading...

Compartilhe esta Página