Skip to content

Commit

Permalink
Enable check-invalid-hooks-usage by default
Browse files Browse the repository at this point in the history
  • Loading branch information
lilactown committed Apr 17, 2021
1 parent 51e758e commit b7a56a9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/helix/core.clj
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@

;; feature flags
flag-fast-refresh? (:fast-refresh feature-flags)
flag-check-invalid-hooks-usage? (:check-invalid-hooks-usage feature-flags)
flag-check-invalid-hooks-usage? (:check-invalid-hooks-usage feature-flags true)
flag-define-factory? (:define-factory feature-flags)
flag-metadata-optimizations (:metadata-optimizations feature-flags)

Expand Down Expand Up @@ -233,7 +233,7 @@

;; feature flags
flag-fast-refresh? (:fast-refresh feature-flags)
flag-check-invalid-hooks-usage? (:check-invalid-hooks-usage feature-flags)]
flag-check-invalid-hooks-usage? (:check-invalid-hooks-usage feature-flags true)]
(when-not (string/starts-with? (str sym) "use-")
(hana/warn hana/warning-invalid-hook-name &env {:form &form}))
`(defn ~(vary-meta sym merge {:helix/hook? true})
Expand Down

0 comments on commit b7a56a9

Please sign in to comment.