Skip to content

If else ----> 'Object map' #79

@Jbarget

Description

@Jbarget

This is getting quite crazy: https://github.com/fac-12/BudgetPlanner/blob/master/src/router.js#L6-L31

A more scalable way of doing this would be to use whats called an object map, see below for an example:
https://github.com/sofer/sssk/blob/master/router.js

If you're confused just let me know and I can explain further :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions