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

Really need ***Payload.Type as static property? #86

Closed
tetsuharuohzeki opened this issue Feb 20, 2017 · 1 comment
Closed

Really need ***Payload.Type as static property? #86

tetsuharuohzeki opened this issue Feb 20, 2017 · 1 comment

Comments

@tetsuharuohzeki
Copy link
Contributor

tetsuharuohzeki commented Feb 20, 2017

  1. These are used to check the type of them.
  2. However, by Use a type gurad function to check derived Payload #79, we can use the type guard function to check it.
  3. To get the "tag" string to define a type, we can use TYPE via import for each modules by Convert src/ to TypeScript #68
  4. By these thing, Do we really need ***Payload.Type as static property?
@tetsuharuohzeki tetsuharuohzeki changed the title Really need ***Payload.Type? Really need ***Payload.Type as static property? Feb 20, 2017
@azu
Copy link
Member

azu commented Feb 20, 2017

Do we really need ***Payload.Type as static property?

@saneyuki Short answer is, No.
I think that each TYPE is private value.
But, We already know that internal constant value(we think) is not truly private.

We can make it secure by removing ***Payload.TYPE getter.

tetsuharuohzeki added a commit to tetsuharuohzeki/almin that referenced this issue Feb 20, 2017
- Breaking Change
- Fix almin#86
- To detect the type of `***Payload`, you should use `is***Payload()`.
tetsuharuohzeki added a commit to tetsuharuohzeki/almin that referenced this issue Feb 20, 2017
- Breaking Change
- Fix almin#86
- To detect the type of `***Payload`, you should use `is***Payload()`.
@azu azu closed this as completed in #87 Feb 20, 2017
azu pushed a commit that referenced this issue Feb 20, 2017
- Breaking Change
- Fix #86
- To detect the type of `***Payload`, you should use `is***Payload()`.
@azu azu mentioned this issue Feb 20, 2017
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