Skip to content

More concisedom_node and ref handling for jquery #62

Closed
@catmando

Description

@catmando

currently you can grab a components ref mapped to jquery using the dom keyword:

INPUT(dom: set(:_input) ... )

it works just like ref, but the resulting value is wrapped by jQuery.

however if you say self.dom_node you get your own ref, and if you want jQuery you say DOM[dom_node]

Seems not very symmetrical.

I am suggesting we do something like this:

dom keyword -> jQuery wrapped reference
ref keyword -> reference

self.dom -> jQuery wrapped reference to self
self.ref -> straight dom reference to self.

and that is the problem ... its sort of backwards.

So alternative proposal:

dom keyword is synonym for ref
jq keyword is ref/dom wrapped by jquery

likewise self.dom is ref to yourself and
self.jq is your self wrapped by jquery

Any other ideas for a pair of names that could be used consistently in both places?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestready-to-releaseInternal Use Only: Has been fixed, specs passing and pushed to edge branch

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions