Skip to content

refactor: revert to legacy decorators#109

Open
buschtoens wants to merge 1 commit into
ember-decorators:masterfrom
buschtoens:refactor/legacy-decorators
Open

refactor: revert to legacy decorators#109
buschtoens wants to merge 1 commit into
ember-decorators:masterfrom
buschtoens:refactor/legacy-decorators

Conversation

@buschtoens

Copy link
Copy Markdown
Contributor

This reverts this addon to use stage 1 / legacy decorators again and also upgrades a bunch of dependencies.

@buschtoens

Copy link
Copy Markdown
Contributor Author

Compatibility notes in README need to be updated.

Let me know, if you feel that patch-method + ember-auto-import is to heavyweight and we should just monkey patch init in place.

@buschtoens

Copy link
Copy Markdown
Contributor Author

#105 also still remains, I guess.

@alexlafroscia alexlafroscia left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thanks for taking the time to upgrade this!

import Component from '@ember/component';
import { assert } from '@ember/debug';
import collapseProto from '@ember-decorators/utils/collapse-proto';
import { afterMethod } from 'patch-method';

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great! Really helpful utility here

@alexlafroscia

Copy link
Copy Markdown
Collaborator

It looks like on beta and canary, rather than "resolving" a computed property and getting the actual value, it instead is seeing the type to check against as ComputedProperty

Any idea why that behavior would have changed in the next beta/canary version of Ember?

@miguelcobain

Copy link
Copy Markdown
Contributor

@buschtoens @alexlafroscia do you think this will be happening anytime soon?

I'm considering dropping @ember-decorators/argument in my ember-yeti-table addon to make it compatible with latest ember and native ember decorators.

It would be nice to get some updates. Thank you!

@alexlafroscia

Copy link
Copy Markdown
Collaborator

I could take a look at why the PR isn't working, but @buschtoens probably has more context on why things aren't working.

Honestly, I would probably just remove @argument until the decorators stuff has fully resolved. Even having done a lot of the work on this add-on, it's mostly just been a pain point for me! I'm not sure the runtime validation is worth the developer overhead.

@cah-brian-gantzler

Copy link
Copy Markdown

While working on a PR for yeti-table that was eventually merged, the @argument actually caught a few bugs of mine and saved me time. I found it very useful

@miguelcobain

Copy link
Copy Markdown
Contributor

I wonder if migrating to Typescript is a 1:1 equivalence?

@jelhan

jelhan commented Sep 25, 2019

Copy link
Copy Markdown

This might fix #111.

@theseyi

theseyi commented Nov 28, 2019

Copy link
Copy Markdown

Is this still in progress? Sorry, I know I'm asking before the holidays

@buschtoens

Copy link
Copy Markdown
Contributor Author

I'm not working on it, sorry. I'm not actively using this addon, as it does not work with Glimmer components.

@alexlafroscia

alexlafroscia commented Nov 28, 2019 via email

Copy link
Copy Markdown
Collaborator

@theseyi

theseyi commented Nov 28, 2019 via email

Copy link
Copy Markdown

@alexlafroscia

alexlafroscia commented Nov 29, 2019 via email

Copy link
Copy Markdown
Collaborator

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.

6 participants