GithubHelp home page GithubHelp logo

Comments (7)

rwjblue avatar rwjblue commented on June 19, 2024

Ya, we should fix this. We can build in assumptions about Ember's built-in components, but we cannot make any assumptions about the others.

tldr; IMHO, this codemod should not be migrating away from arguments to attributes in non-built-in components.

from ember-angle-brackets-codemod.

Turbo87 avatar Turbo87 commented on June 19, 2024

@rwjblue how do you feel about class?

from ember-angle-brackets-codemod.

rwjblue avatar rwjblue commented on June 19, 2024

It depends on what level of "safety" we are shooting for. class is absolutely a value that folks might use and munge in their JS, and assuming that their JS does not need access to it is conceptually breaking.

from ember-angle-brackets-codemod.

Turbo87 avatar Turbo87 commented on June 19, 2024

I had similar thoughts but then couldn't come up with a realistic scenario where it actually mattered for the class attribute. But I'm fine either way. the safest way is definitely to pass it as an argument instead of attribute.

from ember-angle-brackets-codemod.

tylerturdenpants avatar tylerturdenpants commented on June 19, 2024

SO as an example, it should not do:

{{foo-bar class="baz"}}

to

<FooBar class="baz"/>

but rather

<FooBar @class="baz"/>

correct?

from ember-angle-brackets-codemod.

Turbo87 avatar Turbo87 commented on June 19, 2024

@tylerturdenpants yeah, exactly. except maybe for builtin components like input and textarea.

from ember-angle-brackets-codemod.

tylerturdenpants avatar tylerturdenpants commented on June 19, 2024

Ok. Crystal clear now. Thanks.

from ember-angle-brackets-codemod.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.