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

Proxies #16

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Proxies #16

wants to merge 3 commits into from

Conversation

rafaelrocha
Copy link

The tests are still green, should I make them red? Any direction about it?

What it covers:

  • How to create
  • How target and handler behave

What it still does not cover:

  • Revoke

@JonathanPrince
Copy link
Contributor

Is it correct to assume that this currently will only work in Firefox 39+ and Edge?

@rafaelrocha
Copy link
Author

I thought that Babel had support to it but after check its docs, seems like they do not. So based on caniuse.com you are right @JonathanPrince .

I even ended up trying to make it work on Chrome enabling the flag “Enable Experimental JavaScript" but it didn't work as well.

@wolframkriesing
Copy link
Collaborator

Wow, Rafael, this looks awesome. I will have a deeper look into it today. Normally I am trying to cover as little as possible or in other words, as focused as possible in on kata. So that the learning about one feature is deeper.
Lately I also started to create a "the API" kata where it makes sense, that goes a little bit more in breadth than into depth, like here http://tddbin.com/#?kata=es6/language/set/api which I hope makes it easier for one to decide where to work on,

  1. either on the "going-into-depth" kata, which would be about one single method (like delete http://tddbin.com/#?kata=es6/language/set/delete ) of e.g. the Set API or
  2. on getting to know all the stuff about it quickly doing the "the API" kata. Or even the
  3. which is "basics" which just tries to introduce the topic/API/object.
    Where do you think your one would fit? Currently it's trying to cover a lot, right?
    What do you think about shrinking it into either one?
    just so you know this is what it currently then looks like for Set on the es6katas page

bildschirmfoto 2015-07-28 um 10 09 04

@rafaelrocha
Copy link
Author

Thanks @wolframkriesing.

I see your point and I'm pretty sure that an API Kata for Proxy would be great but I think the way the Proxy behave and interact with the target and handler objects should be learned first than the whole API. I see proxy concept much more related to the way an object behave than the way it interfaces with others.

I agree with you that this first draft is going deep so instead of choose one of your two options and based on the Set Katas, I suggest us to split Proxy Katas like the following:

Basics

  • Create
  • Intercession

Behaviour/Flow

  • Target
  • Handler

Api

  • Available traps
  • Revoke

What do you think?

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

Successfully merging this pull request may close these issues.

3 participants