question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Deprecate var, invoke, assign

See original GitHub issue

With the new $ <code> syntax, we have a better way to add JS to a template and no longer need these tags. We do want to make them available for the v3 -> v4 migration. Should we just add a deprecation warning or split them out into a marko-v3-compat package?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:16 (13 by maintainers)

github_iconTop GitHub Comments

1reaction
gilbertcommented, Feb 3, 2017

The introduction of $ var flavor=input.someFunc() kill the template and you end up with PHP all over again.

Let’s be honest here: We don’t get PHP simply because of <? ?> tags. Unless you consider Ruby on Rails and ERB to be PHP as well!

I do find the <var x=10>...</var> feature interesting. To avoid potential confusion with JS, maybe you could rename it to something like <scoped x=10>, for those who want that feature.

1reaction
gilbertcommented, Feb 2, 2017

I think a migration package is a good idea. If one intends to move from v3 to v4, installing a package would be the least of those efforts.

What do you mean by sub packages that export tags?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why does my variable show it's deprecated? - Stack Overflow
In VS Code, find the variable name where it is showing deprecated name. Put your cursor and right click on it, then select...
Read more >
Approaches to Deprecating Code in JavaScript | CSS-Tricks
In my opinion, large teams or projects relying on external APIs or libraries ought to deprecate first, then remove later (after a reasonable ......
Read more >
Stop using var for declaring variables !!! - DEV Community ‍ ‍
To achieve this, we eliminate the use of var for declaring a variable and use let & const instead for variable declaration.
Read more >
Underscore.js
Underscore provides over 100 functions that support both your favorite workaday functional helpers: map, filter, invoke — as well as more specialized ...
Read more >
How do I use Custom Variables? (deprecated) FAQ
Custom variables are assigned in JavaScript by calling setCustomVariable( index, name, value, scope ) to set a new custom variable to a visitor ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found