Skip to content

proposal: reserve $$ or $- for non-JRI keywords #6

Open
@DavidBiesack

Description

@DavidBiesack

The proposal says:

JRI keywords MUST start with a "$" character. Context specifications MAY define their own "$"-prefixed keywords, however this is NOT RECOMMENDED as future specifications that extend JRI as discussed in {{extending}} will use that prefix.

I propose that the proposal extend to allow $$ as a safe prefix that will never be used by JRI.

For example, I may choose to define an object with "$ref": , "$$ref-prod": , "$$ref-qa":, in source to allow specifying alternates URIs , where preprocessing tools on the source can hot-swap $ref and $$ref-prod or $$ref-qa alternatives within a build/deploy pipeline. This could be used where static template or other token substitution does not work well.

Context specifications MAY safely use the "$$" prefix sequence for context keywords. Future JRI keywords MUST NOT start with the "$$" prefix sequence.

(Given that, the proposal could tighten this and say that Context specifications MAY NOT define their own "$"-prefixed keyword unless they use the "$$" prefix.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    jriRelated to the JRI (JSON Referencing and Identification) proposal

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions