Giter VIP home page Giter VIP logo

Comments (5)

MartinJohns avatar MartinJohns commented on May 23, 2024 2

disallowAssertKeywords sounds super generic and can mistakenly interpreted to refer to asserts too. And "keywords" is pluralized, but I'm not sure to what other keyword this option refers to?

Perhaps something like disallowAssertImports would be better?

from typescript.

a-tarasyuk avatar a-tarasyuk commented on May 23, 2024 1

The option name is open to discussion. However, it's more important to determine whether we need to add this new option or if this deprecation should be handled by the ignoreDeprecations option.

from typescript.

RyanCavanaugh avatar RyanCavanaugh commented on May 23, 2024

I think the most likely course of action is to deprecate the syntax in 6.0 with a compat flag for a little bit. A lint rule is probably the best choice if you need to ban this right away in some other scenario

from typescript.

petamoriken avatar petamoriken commented on May 23, 2024

I think the most likely course of action is to deprecate the syntax in 6.0 with a compat flag for a little bit.

👍

The DENO_FUTURE=1 environment variable disables the assert keywords in JavaScript, so I would like to gradually disable assert keywords in TypeScript as well by adding the disallowAssertKeywords option.
denoland/deno#23541

A lint rule is probably the best choice if you need to ban this right away in some other scenario

The no-import-assertions rule is already implemented in deno_lint and is enabled by default.
denoland/deno_lint#1209

from typescript.

a-tarasyuk avatar a-tarasyuk commented on May 23, 2024

@RyanCavanaugh Should the disallowAssertKeywords option be added, or would this be considered an addition to the list of deprecated items?

from typescript.

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.