@ashstack/lint 0.3.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (129) hide show
  1. package/README.md +25 -2
  2. package/dist/core/index.d.ts +4 -2
  3. package/dist/core/index.js +1 -1
  4. package/dist/core/rules/core/no-comments.js +1 -1
  5. package/dist/lib/ast.js +1 -1
  6. package/dist/lib/effect-plugin.js +1 -0
  7. package/dist/lib/types.d.ts +5 -0
  8. package/dist/react/index.d.ts +2 -0
  9. package/dist/react/index.js +1 -1
  10. package/dist/react/rules/query/next-page-param-undefined.js +1 -1
  11. package/dist/react/rules/query/no-fetch-in-query-fn.js +1 -1
  12. package/dist/react/rules/query/no-inline-keys.js +1 -1
  13. package/dist/react/rules/react/index.js +1 -0
  14. package/dist/react/rules/react/no-svg-without-title.js +1 -0
  15. package/dist/react/rules/react/no-unlabeled-icon-button.js +1 -0
  16. package/dist/react/rules/react/shared.js +1 -0
  17. package/dist/react/rules/tailwind/index.js +1 -0
  18. package/dist/react/rules/tailwind/prefer-cn.js +1 -0
  19. package/dist/react/rules/tailwind/shared.js +1 -0
  20. package/dist/react/rules/tailwind/use-logical-classes.js +1 -0
  21. package/dist/react/rules/tanstack-router/index.js +1 -0
  22. package/dist/react/rules/tanstack-router/no-search-casts.js +1 -0
  23. package/dist/react/rules/tanstack-router/require-selector.js +1 -0
  24. package/dist/react/rules/tanstack-router/shared.js +1 -0
  25. package/dist/react-native/index.d.ts +2 -0
  26. package/dist/react-native/index.js +1 -1
  27. package/dist/react-native/rules/legend-list/index.js +1 -1
  28. package/dist/react-native/rules/react-native/no-manual-memo.js +1 -1
  29. package/package.json +11 -11
  30. package/dist/core/rules/core/components-tsx-only.d.ts +0 -2
  31. package/dist/core/rules/core/hoist-intl.d.ts +0 -2
  32. package/dist/core/rules/core/index.d.ts +0 -2
  33. package/dist/core/rules/core/no-comments.d.ts +0 -2
  34. package/dist/core/rules/core/no-naming-convention.d.ts +0 -2
  35. package/dist/core/rules/core/no-packed-condition.d.ts +0 -2
  36. package/dist/core/rules/core/use-design-system.d.ts +0 -2
  37. package/dist/core/rules/zod/index.d.ts +0 -2
  38. package/dist/core/rules/zod/prefer-enum.d.ts +0 -2
  39. package/dist/index.d.ts +0 -4
  40. package/dist/index.js +0 -1
  41. package/dist/lib/ast.d.ts +0 -44
  42. package/dist/lib/detect.d.ts +0 -9
  43. package/dist/lib/merge.d.ts +0 -9
  44. package/dist/lib/module.d.ts +0 -19
  45. package/dist/react/rules/i18n/index.d.ts +0 -2
  46. package/dist/react/rules/i18n/no-bare-attrs.d.ts +0 -2
  47. package/dist/react/rules/i18n/no-bare-text.d.ts +0 -2
  48. package/dist/react/rules/i18n/no-bare-toast.d.ts +0 -2
  49. package/dist/react/rules/query/index.d.ts +0 -2
  50. package/dist/react/rules/query/next-page-param-undefined.d.ts +0 -2
  51. package/dist/react/rules/query/no-deprecated-filters.d.ts +0 -2
  52. package/dist/react/rules/query/no-fetch-in-query-fn.d.ts +0 -2
  53. package/dist/react/rules/query/no-inline-keys.d.ts +0 -2
  54. package/dist/react/rules/query/require-destructured-hooks.d.ts +0 -2
  55. package/dist/react/rules/query/shared.d.ts +0 -2
  56. package/dist/react/rules/query/shared.js +0 -1
  57. package/dist/react/rules/zustand/index.d.ts +0 -2
  58. package/dist/react/rules/zustand/require-selector.d.ts +0 -2
  59. package/dist/react-native/rules/keyboard/index.d.ts +0 -2
  60. package/dist/react-native/rules/legend-list/index.d.ts +0 -2
  61. package/dist/react-native/rules/legend-list/no-flex-in-content-container.d.ts +0 -2
  62. package/dist/react-native/rules/legend-list/no-index-key-extractor.d.ts +0 -2
  63. package/dist/react-native/rules/legend-list/no-inline-data.d.ts +0 -2
  64. package/dist/react-native/rules/legend-list/no-inline-data.js +0 -1
  65. package/dist/react-native/rules/legend-list/no-inline-extra-data.d.ts +0 -2
  66. package/dist/react-native/rules/legend-list/no-inline-extra-data.js +0 -1
  67. package/dist/react-native/rules/legend-list/no-inline-render-item-props.d.ts +0 -2
  68. package/dist/react-native/rules/legend-list/no-mixed-children.d.ts +0 -2
  69. package/dist/react-native/rules/legend-list/no-remount-key.d.ts +0 -2
  70. package/dist/react-native/rules/legend-list/no-scrollview-map.d.ts +0 -2
  71. package/dist/react-native/rules/legend-list/no-unsupported-props.d.ts +0 -2
  72. package/dist/react-native/rules/legend-list/required-props.d.ts +0 -2
  73. package/dist/react-native/rules/legend-list/shared.d.ts +0 -19
  74. package/dist/react-native/rules/legend-list/typed-items-need-item-type.d.ts +0 -2
  75. package/dist/react-native/rules/legend-state/index.d.ts +0 -2
  76. package/dist/react-native/rules/legend-state/naming.d.ts +0 -2
  77. package/dist/react-native/rules/legend-state/no-assignment.d.ts +0 -2
  78. package/dist/react-native/rules/legend-state/no-nested-observable.d.ts +0 -2
  79. package/dist/react-native/rules/legend-state/no-object-selector.d.ts +0 -2
  80. package/dist/react-native/rules/legend-state/no-observable-in-component.d.ts +0 -2
  81. package/dist/react-native/rules/legend-state/no-peek-in-selector.d.ts +0 -2
  82. package/dist/react-native/rules/legend-state/no-react-mirror.d.ts +0 -2
  83. package/dist/react-native/rules/legend-state/no-untracked-get-in-jsx.d.ts +0 -2
  84. package/dist/react-native/rules/legend-state/shared.d.ts +0 -9
  85. package/dist/react-native/rules/react-native/hoist-stateless-function.d.ts +0 -2
  86. package/dist/react-native/rules/react-native/index.d.ts +0 -2
  87. package/dist/react-native/rules/react-native/no-conditional-style-array.d.ts +0 -2
  88. package/dist/react-native/rules/react-native/no-dynamic-import.d.ts +0 -2
  89. package/dist/react-native/rules/react-native/no-keyboard-will-events.d.ts +0 -2
  90. package/dist/react-native/rules/react-native/no-leaked-render.d.ts +0 -2
  91. package/dist/react-native/rules/react-native/no-manual-memo.d.ts +0 -2
  92. package/dist/react-native/rules/react-native/no-redundant-view-nesting.d.ts +0 -2
  93. package/dist/react-native/rules/react-native/no-rn-image-network-source.d.ts +0 -2
  94. package/dist/react-native/rules/react-native/no-rn-namespace-import.d.ts +0 -2
  95. package/dist/react-native/rules/react-native/no-scroll-position-state.d.ts +0 -2
  96. package/dist/react-native/rules/react-native/no-unlabeled-icon-pressable.d.ts +0 -2
  97. package/dist/react-native/rules/reanimated/animated-reaction-safety.d.ts +0 -2
  98. package/dist/react-native/rules/reanimated/animated-style-needs-animated-component.d.ts +0 -2
  99. package/dist/react-native/rules/reanimated/animated-updater-purity.d.ts +0 -2
  100. package/dist/react-native/rules/reanimated/gpu-properties-only.d.ts +0 -2
  101. package/dist/react-native/rules/reanimated/hoist-layout-animation-builder.d.ts +0 -2
  102. package/dist/react-native/rules/reanimated/index.d.ts +0 -2
  103. package/dist/react-native/rules/reanimated/interpolate-needs-clamp.d.ts +0 -2
  104. package/dist/react-native/rules/reanimated/no-react-state-from-continuous-worklet.d.ts +0 -2
  105. package/dist/react-native/rules/reanimated/no-shared-value-dot-value.d.ts +0 -2
  106. package/dist/react-native/rules/reanimated/prefer-lazy-shared-value-initializer.d.ts +0 -2
  107. package/dist/react-native/rules/reanimated/schedule-on-rn-scope.d.ts +0 -2
  108. package/dist/react-native/rules/reanimated/shared-value-usage.d.ts +0 -2
  109. package/dist/react-native/rules/reanimated/shared.d.ts +0 -5
  110. package/dist/react-native/rules/skia/canvas-opaque.d.ts +0 -2
  111. package/dist/react-native/rules/skia/index.d.ts +0 -2
  112. package/dist/react-native/rules/turbo-image/index.d.ts +0 -2
  113. package/dist/react-native/rules/turbo-image/require-cache-policy.d.ts +0 -2
  114. package/dist/react-native/rules/turbo-image/require-resize.d.ts +0 -2
  115. package/dist/react-native/rules/unistyles/animated-theme.d.ts +0 -2
  116. package/dist/react-native/rules/unistyles/content-container.d.ts +0 -2
  117. package/dist/react-native/rules/unistyles/in-sheet.d.ts +0 -2
  118. package/dist/react-native/rules/unistyles/index.d.ts +0 -2
  119. package/dist/react-native/rules/unistyles/insets.d.ts +0 -2
  120. package/dist/react-native/rules/unistyles/no-hardcoded-color.d.ts +0 -2
  121. package/dist/react-native/rules/unistyles/no-hardcoded-spacing.d.ts +0 -2
  122. package/dist/react-native/rules/unistyles/no-margin.d.ts +0 -2
  123. package/dist/react-native/rules/unistyles/no-style-spread.d.ts +0 -2
  124. package/dist/react-native/rules/unistyles/no-unused-styles.d.ts +0 -2
  125. package/dist/react-native/rules/unistyles/rtl-style-call.d.ts +0 -2
  126. package/dist/react-native/rules/unistyles/shared.d.ts +0 -16
  127. package/dist/react-native/rules/unistyles/theme-screen-component.d.ts +0 -2
  128. package/dist/react-native/rules/unistyles/theme-style-attr.d.ts +0 -2
  129. package/dist/react-native/stylesheet.d.ts +0 -11
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noBareAttrs: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noBareText: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noBareToast: Rule;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const nextPageParamUndefined: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noDeprecatedFilters: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noFetchInQueryFn: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noInlineKeys: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const requireDestructuredHooks: Rule;
@@ -1,2 +0,0 @@
1
- import type { AstNode } from "../../../lib/types.js";
2
- export declare const propertyKeyName: (node: AstNode) => string;
@@ -1 +0,0 @@
1
- export const propertyKeyName=(r)=>{if(r.type!=="Property"||r.computed)return"";const{key:e}=r;if(e.type==="Identifier")return e.name;if(e.type==="Literal")return String(e.value);return""};
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const requireSelector: Rule;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noFlexInContentContainer: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noIndexKeyExtractor: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noInlineData: Rule;
@@ -1 +0,0 @@
1
- import{FUNCTION_TYPES as s,calleeName as i,crossesFunctionBefore as n,findInSubtree as o,gate as l,problem as c}from"../../../lib/ast.js";import{attributeNamed as d,expressionOf as u,isListElement as f,LIST as m}from"./shared.js";const p=new Set(["useMemo","useCallback"]),h=(e)=>e.type==="ArrayExpression"||e.type==="CallExpression"&&e.callee.type==="MemberExpression";export const noInlineData=c("Disallow building a Legend List's `data` inline. Each render produces a new array reference, and the list re-diffs, re-keys and drops what it had cached.",{createOnce:(e)=>({before:()=>l(e,m),JSXElement(t){if(!f(t))return;const r=d(t,"data");if(!r)return;if(p.has(i(u(r))))return;const a=o(r.value,h);if(!a||n(a,r,s))return;e.report({node:r,message:"Hoist this `data` into a `useMemo` or compute it upstream so its reference is stable. A new array each render makes the list re-diff, re-key and invalidate everything it had cached."})}})});
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noInlineExtraData: Rule;
@@ -1 +0,0 @@
1
- import{attributeName as n,gate as i,problem as s}from"../../../lib/ast.js";import{expressionOf as o,isListElement as l,literalKind as u}from"./shared.js";export const noInlineExtraData=s("An inline object or array as `extraData` takes a new identity on every parent render, and every mounted row re-evaluates with it.",{createOnce:(a)=>({before:()=>i(a,"extraData"),JSXAttribute(e){if(n(e)!=="extraData")return;if(!l(e.parent.parent))return;const t=o(e),r=u(t);if(t===null||r===null)return;a.report({node:t,message:`Pass the primitive that actually changed as \`extraData\`, or hoist this ${r} when it is stable. A fresh ${r} reference each render re-evaluates every mounted row.`})}})});
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noInlineRenderItemProps: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noMixedChildren: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noRemountKey: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noScrollviewMap: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noUnsupportedProps: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const requiredProps: Rule;
@@ -1,19 +0,0 @@
1
- import type { AstNode } from "../../../lib/types.js";
2
- /** A JSX element node, the only shape the list rules look at. */
3
- export type ListElement = Extract<AstNode, {
4
- type: "JSXElement";
5
- }>;
6
- type Attribute = Extract<AstNode, {
7
- type: "JSXAttribute";
8
- }>;
9
- type AttributeItem = Extract<AstNode, {
10
- type: "JSXAttribute" | "JSXSpreadAttribute";
11
- }>;
12
- export declare const LIST = "LegendList";
13
- export declare const isListElement: (node: AstNode | null | undefined) => boolean;
14
- export declare const attributesOf: (node: AstNode) => AttributeItem[];
15
- export declare const attributeNamed: (node: AstNode, wanted: string) => Attribute | undefined;
16
- export declare const hasSpread: (node: AstNode) => boolean;
17
- export declare const expressionOf: (attribute: AstNode | null | undefined) => AstNode | null;
18
- export declare const literalKind: (node: AstNode | null | undefined) => "object" | "array" | null;
19
- export {};
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const typedItemsNeedItemType: Rule;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const naming: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noAssignment: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noNestedObservable: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noObjectSelector: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noObservableInComponent: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noPeekInSelector: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noReactMirror: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noUntrackedGetInJsx: Rule;
@@ -1,9 +0,0 @@
1
- import type { AstNode, RuleContext } from "../../../lib/types.js";
2
- export declare const OBSERVABLE_FACTORIES: Set<string>;
3
- /** The trailing `$` that marks an observable binding. */
4
- export declare const OBS: RegExp;
5
- export declare const isObservableRef: (node: AstNode | null | undefined) => boolean;
6
- /** The factory name when this call is `observable(...)` or `useObservable(...)`. */
7
- export declare const factoryCalled: (node: AstNode | null | undefined) => string | null;
8
- /** Source text for a node, for quoting it back in a message. */
9
- export declare const textOf: (context: RuleContext, node: AstNode) => string;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const hoistStatelessFunction: Rule;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noConditionalStyleArray: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noDynamicImport: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noKeyboardWillEvents: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noLeakedRender: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noManualMemo: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noRedundantViewNesting: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noRnImageNetworkSource: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noRnNamespaceImport: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noScrollPositionState: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noUnlabeledIconPressable: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const animatedReactionSafety: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const animatedStyleNeedsAnimatedComponent: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const animatedUpdaterPurity: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const gpuPropertiesOnly: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const hoistLayoutAnimationBuilder: Rule;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const interpolateNeedsClamp: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noReactStateFromContinuousWorklet: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noSharedValueDotValue: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const preferLazySharedValueInitializer: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const scheduleOnRnScope: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const sharedValueUsage: Rule;
@@ -1,5 +0,0 @@
1
- import type { AstNode } from "../../../lib/types.js";
2
- /** `useSharedValue(...)` and friends, under a namespace or not — decides which locals hold a shared value. */
3
- export declare const isProducerCall: (node: AstNode | null | undefined) => boolean;
4
- /** The hooks whose callback is an animated updater. */
5
- export declare const ANIMATED_STYLE_HOOKS: Set<string>;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const canvasOpaque: Rule;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const requireCachePolicy: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const requireResize: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const animatedTheme: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const contentContainer: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const inSheet: Rule;
@@ -1,2 +0,0 @@
1
- declare const _default: import("../../../index.js").ModuleManifest;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const insets: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noHardcodedColor: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noHardcodedSpacing: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noMargin: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noStyleSpread: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const noUnusedStyles: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const rtlStyleCall: Rule;
@@ -1,16 +0,0 @@
1
- import type { AstNode, Rule, RuleContext, Visitor } from "../../../lib/types.js";
2
- export { CREATE_MARKER, isStyleSheetCreate, propertyName, stylesObjectOf, type StylesObject, } from "../../stylesheet.js";
3
- export declare const memberPath: (node: AstNode | null | undefined) => string;
4
- export declare const declaresUseUnistylesTheme: (scope: AstNode) => boolean;
5
- /**
6
- * The enclosing function that destructures a `useUnistyles()` theme, innermost first. Walking past the
7
- * innermost function matters: the read is often inside a callback the component passes down.
8
- */
9
- export declare const themeConsumingComponent: (node: AstNode) => AstNode | null;
10
- export declare const readsTheme: (node: AstNode) => boolean;
11
- /**
12
- * Builds a rule whose visitors only fire inside `StyleSheet.create(...)`, by tracking how deeply
13
- * nested the traversal currently is in such a call. The depth resets per file in `before()`, which
14
- * also runs the text gate.
15
- */
16
- export declare const inCreate: (description: string, visit: (context: RuleContext, inside: () => boolean) => Visitor) => Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const themeScreenComponent: Rule;
@@ -1,2 +0,0 @@
1
- import type { Rule } from "../../../lib/types.js";
2
- export declare const themeStyleAttr: Rule;
@@ -1,11 +0,0 @@
1
- import type { AstNode } from "../lib/types.js";
2
- /** The object literal a stylesheet is built from. */
3
- export type StylesObject = Extract<AstNode, {
4
- type: "ObjectExpression";
5
- }>;
6
- /** Source-text gate for the stylesheet rules. Just the object, so `StyleSheet\n .create(...)` still counts. */
7
- export declare const CREATE_MARKER = "StyleSheet";
8
- export declare const isStyleSheetCreate: (node: AstNode | null | undefined) => boolean;
9
- export declare const propertyName: (node: AstNode) => string;
10
- /** The styles object a `StyleSheet.create` argument holds: a literal, or the one its theme function returns. */
11
- export declare const stylesObjectOf: (factory: AstNode | null | undefined) => StylesObject | null;