Skip to content

⬅️ Back to Table of Contents

📄 no-loss-of-precision

📊 Analysis Summary

Metric Count
🔧 Functions 1
📦 Imports 4
📑 Type Aliases 2

📚 Table of Contents

🛠️ File Location:

📂 packages/eslint-plugin/src/rules/no-loss-of-precision.ts

📤 Default Export

export default createRule<Options, MessageIds>({ ... })
Property Value
name 'no-loss-of-precision'
meta.type 'problem'
meta.deprecated.deprecatedSince '8.0.0'
meta.deprecated.replacedBy [ { rule: { name: 'no-loss-of-precision', url: 'https://eslint.org/docs/latest/rules/no-loss-of-precision', }, }, ]
meta.deprecated.url 'https://github.com/typescript-eslint/typescript-eslint/pull/8832'
meta.docs.description 'Disallow literal numbers that lose precision'
meta.docs.extendsBaseRule true
meta.hasSuggestions baseRule.meta.hasSuggestions
meta.messages baseRule.meta.messages
meta.schema []
defaultOptions []

Entry point: create — documented under Functions.


📦 Imports

Name Source
InferMessageIdsTypeFromRule ../util
InferOptionsTypeFromRule ../util
createRule ../util
getESLintCoreRule ../util/getESLintCoreRule

Functions

create(context: any): any

Parameters:

  • context any

Returns: any

Calls:

  • baseRule.create
Code
create(context) {
    return baseRule.create(context);
  }

Type Aliases

Options

type Options = InferOptionsTypeFromRule<NonNullable<typeof baseRule>>;

MessageIds

type MessageIds = InferMessageIdsTypeFromRule<
  NonNullable<typeof baseRule>
>;

Generated by Syntax Scribe