Giter Site home page Giter Site logo

Comments (3)

dummdidumm avatar dummdidumm commented on June 11, 2024 2

I think we should preserve the Svelte 4 behavior in legacy mode but introduce the more strict behavior in runes mode (so that we can eventually remove the logic of reordering them)

from svelte.

AdrianGonz97 avatar AdrianGonz97 commented on June 11, 2024 1

This issue can be boiled down to if the order of @const tag declarations now matter in Svelte 5 and if it's an intended breaking change:

Svelte 4

Svelte 5

from svelte.

sparecycles avatar sparecycles commented on June 11, 2024

Svelte4 had too much magic. 😁

There's a third option which is requiring an additional flag for this logic (if it's primarily an issue for library-generated code, since client code can always reorder easily):

Pro

  • encourages library developers to support the new rules (rather than tell users to apply the flag), and at the same time
  • unblocks the rest of the transition of code to runes for code reliant on broken libraries

Con

  • now users will have this flag in their code.
  • more compiler modes to test.
  • more to document.

from svelte.

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.