Skip to content

Commit

Permalink
chore: fix readme syntax again
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshuaKGoldberg committed Feb 9, 2023
1 parent aa7ea5d commit c5bfa64
Showing 1 changed file with 42 additions and 42 deletions.
84 changes: 42 additions & 42 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ npm i ts-api-utils
```

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";
```

`ts-api-utils` provides several categories of utility functions:
Expand Down Expand Up @@ -67,7 +67,7 @@ Iterates over all comments owned by `node` or its children.
- `function forEachComment(node: ts.Node, callback: ForEachCommentCallback, sourceFile?: ts.SourceFile): void`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -89,7 +89,7 @@ This function only handles boolean flags.
- `function isCompilerOptionEnabled(options: ts.CompilerOptions, option: BooleanCompilerOptions): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

const options = {
allowJs: true,
Expand All @@ -107,7 +107,7 @@ Checks if a given compiler option is enabled, accounting for whether all flags (
- `function isStrictCompilerOptionEnabled(options: ts.CompilerOptions, option: StrictCompilerOption): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

const optionsLenient = {
noImplicitAny: true,
Expand All @@ -132,7 +132,7 @@ tsutils.isStrictCompilerOptionEnabled(optionsStrict, "noImplicitThis"); // false
- `function isModifierFlagSet(node: ts.Declaration, flag: ts.ModifierFlags): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -144,7 +144,7 @@ tsutils.isModifierFlagSet(node, ts.ModifierFlags.Abstract);
- `function isNodeFlagSet(node: ts.Node, flag: ts.NodeFlags): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -156,7 +156,7 @@ tsutils.isNodeFlagSet(node, ts.NodeFlags.AwaitContext);
- `function isObjectFlagSet(node: ts.ObjectType, flag: ts.ObjectFlags): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -168,7 +168,7 @@ tsutils.isObjectFlagSet(node, ts.ObjectFlags.Anonymous);
- `function isSymbolFlagSet(symbol: ts.Symbol, flag: ts.SymbolFlags): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const symbol: ts.Symbol;

Expand All @@ -180,7 +180,7 @@ tsutils.isSymbolFlagSet(symbol, ts.SymbolFlags.Accessor);
- `function isTypeFlagSet(type: ts.Type, flag: ts.TypeFlags): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -194,7 +194,7 @@ tsutils.isTypeFlagSet(type, ts.TypeFlags.Any);
- `function isEntityNameExpression(node: ts.Node): node is ts.EntityNameExpression`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -206,7 +206,7 @@ tsutils.isEntityNameExpression(node);
- `function isExpression(node: ts.Node): node is ts.Expression`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -218,7 +218,7 @@ tsutils.isExpression(node);
- `function isNumericOrStringLikeLiteral(node: ts.Node): node is NumericOrStringLikeLiteral`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -230,7 +230,7 @@ tsutils.isNumericOrStringLikeLiteral(node);
- `function isParameterDeclaration(node: ts.Node): node is ts.ParameterDeclaration`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -242,7 +242,7 @@ tsutils.isParameterDeclaration(node);
- `function isConstAssertion(node: ts.AssertionExpression): node is ConstAssertionExpression`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -258,7 +258,7 @@ Determines whether a call to `Object.defineProperty` is statically analyzable.
- `function isBindableObjectDefinePropertyCall(node: ts.CallExpression): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -272,7 +272,7 @@ Detects whether an expression is affected by an enclosing 'as const' assertion a
- `function isInConstContext(node: ts.Expression): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Expression;

Expand All @@ -286,7 +286,7 @@ tsutils.isInConstContext(node);
- `function hasModifier(modifiers: Iterable<ts.Modifier> | undefined, ...kinds: ts.Modifier): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const modifiers: ts.Modifier[];

Expand All @@ -301,7 +301,7 @@ tsutils.hasModifier(modifiers, ts.SyntaxKind.AbstractKeyword);
- `function isFunctionScopeBoundary(node: ts.Node): ScopeBoundary`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -315,7 +315,7 @@ tsutils.isFunctionScopeBoundary(node);
- `function isAssignmentKind(kind: ts.SyntaxKind): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const kind: ts.SyntaxKind;

Expand All @@ -327,7 +327,7 @@ tsutils.isAssignmentKind(kind);
- `function isNumericPropertyName(name: string | ts.__String): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

tsutils.isNumericPropertyName("abc"); // false
tsutils.isNumericPropertyName("123"); // true
Expand All @@ -340,7 +340,7 @@ Determines whether the given text can be used to access a property with a Proper
- `function isValidPropertyAccess(text: string, languageVersion?: ts.ScriptTarget): void`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

tsutils.isValidPropertyAccess("abc"); // true
tsutils.isValidPropertyAccess("123"); // false
Expand All @@ -356,7 +356,7 @@ Iterates over all tokens of `node`.
- `function forEachToken(node: ts.Node, callback: ForEachTokenCallback, sourceFile?: ts.SourceFile): void`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;

Expand All @@ -372,7 +372,7 @@ tsutils.forEachToken(node, (token) => {
- `function getCallSignaturesOfType(type: ts.Type): readonly ts.Signature[]`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -384,7 +384,7 @@ tsutils.getCallSignaturesOfType(type);
- `function getPropertyOfType(type: ts.Type, name: ts.__String): ts.Symbol | undefined`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const property: ts.Symbol;
declare const type: ts.Type;
Expand All @@ -399,7 +399,7 @@ tsutils.getPropertyOfType(type, property.getEscapedName());
- `function isConditionalType(type: ts.Type): type is ts.ConditionalType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -411,7 +411,7 @@ tsutils.isConditionalType(type);
- `function isIntersectionType(type: ts.Type): type is ts.IntersectionType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -423,7 +423,7 @@ tsutils.isIntersectionType(type);
- `function isLiteralType(type: ts.Type): type is ts.LiteralType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -435,7 +435,7 @@ tsutils.isLiteralType(type);
- `function isObjectType(type: ts.Type): type is ts.ObjectType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -447,7 +447,7 @@ tsutils.isObjectType(type);
- `function isUnionOrIntersectionType(type: ts.Type): type is ts.UnionOrIntersectionType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -459,7 +459,7 @@ tsutils.isUnionOrIntersectionType(type);
- `function isUnionType(type: ts.Type): type is ts.UnionType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -471,7 +471,7 @@ tsutils.isUnionType(type);
- `function isUniqueESSymbolType(type: ts.Type): type is ts.UniqueESSymbolType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -483,7 +483,7 @@ tsutils.isUniqueESSymbolType(type);
- `function isTupleType(type: ts.Type): type is ts.TupleType`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -495,7 +495,7 @@ tsutils.isTupleType(type);
- `function isTupleTypeReference(type: ts.Type): type is TupleTypeReference`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -507,7 +507,7 @@ tsutils.isTupleTypeReference(type);
- `function isTypeReference(type: ts.Type): type is ts.TypeReference`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -521,7 +521,7 @@ tsutils.isTypeReference(type);
- `function getWellKnownSymbolPropertyOfType(type: ts.Type, wellKnownSymbolName: string, typeChecker: ts.TypeChecker): ts.Symbol | undefined`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;
declare const typeChecker: ts.TypeChecker;
Expand All @@ -536,7 +536,7 @@ Determines whether the given type is a boolean literal type and matches the give
- `function isBooleanLiteralType(type: ts.Type, literal: boolean)`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -551,7 +551,7 @@ This function doesn't unwrap union types.
- `function isFalsyType(type: ts.Type): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand All @@ -565,7 +565,7 @@ Determines whether writing to a certain property of a given type is allowed.
- `function isPropertyReadonlyInType(type: ts.Type, name: ts.__String, typeChecker: ts.TypeChecker): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const property: ts.Symbol;
declare const type: ts.Type;
Expand All @@ -582,7 +582,7 @@ Determines whether a type is thenable and thus can be used with `await`.
- `function isThenableType(typeChecker: ts.TypeChecker, node: ts.Expression, type?: ts.Type): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const node: ts.Node;
declare const type: ts.Type;
Expand All @@ -603,7 +603,7 @@ tsutils.isThenableType(typeChecker, expression, type);
- `function someTypePart(type: ts.Type, predicate: SomeTypePartPredicate, callback: SomeTypePartCallback): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;
declare const typeChecker: ts.TypeChecker;
Expand All @@ -618,7 +618,7 @@ tsutils.someTypePart(type, tsutils.isUnionOrIntersectionType, (subType) => {
- `function symbolHasReadonlyDeclaration(symbol: ts.Symbol, typeChecker: ts.TypeChecker): boolean`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const symbol: ts.Symbol;
declare const typeChecker: ts.TypeChecker;
Expand All @@ -631,7 +631,7 @@ tsutils.symbolHasReadonlyDeclaration(symbol, typeChecker);
- `function unionTypeParts(type: ts.Type): ts.Type[]`

```ts
import * as tsutils. "ts-api-utils";
import * as tsutils from "ts-api-utils";

declare const type: ts.Type;

Expand Down

0 comments on commit c5bfa64

Please sign in to comment.