Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename column in Land Civilian modifiers from Capability to Category #15

Open
spatialillusions opened this issue Mar 18, 2023 · 1 comment

Comments

@spatialillusions
Copy link
Owner

Would be a breaking change, but would unify all tables. What do you think?

@kjellmf
Copy link
Contributor

kjellmf commented Mar 18, 2023

Making breaking changes are fine as long as you update the major version accordingly. I use data from your standards libraries in orbat-mapper, but rename several of the columns/keys internally like this:

const mappings = {
    "symbolset": "symbolSet",
    "Entity": "entity",
    "Entity Type": "entityType",
    "Entity Subtype": "entitySubtype",
    "Code": "code",
    "Remarks": "remarks",
    "modifier1" : "modifierOne",
    "modifier2" : "modifierTwo",
    "First Modifier": "modifier",
    "Second Modifier": "modifier",
    "Geometric Rendering": "geometry",
    "Capability": "category",
    "Category": "category",
}

The reason I do this is to make the data slightly easier to work with in code. Example:

const label = symbol["Entity Subtype"] || symbol["Entity Type"] || symbol["Entity"];

// vs

const label = symbol.entitySubtype || symbol.entityType || symbol.entity;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants