Skip to content

Commit 3b22325

Browse files
JeroenBoersmacalebporzioclaude
authored
Don't assign the normalEvaluator per default (#4548)
* Don't assign the normalEvaluator per default Assigning the normal evaluator to theEvaluatorFunction means that it always needs to be exported. CSP doesn't use the normalEvaluator and should not include it in any build. alpinsjs/src/index.js always assigns the normalEvaluator manually and works as expected, and it isn't included anymore in the csp builds. * normalEvaluator also needed dependencies for unsafe functions which we don't want to include in the csp build * Generate sourcemap files for the generated files + it would really helpfull for developers to have sourcemap files alongside of the js and minified js files * Review fixes: remove unrelated sourcemap addition from build.js The sourcemap change is unrelated to the CSP evaluator fix and should be a separate PR if desired. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Caleb Porzio <calebporzio@gmail.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent f0eb794 commit 3b22325

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/alpinejs/src/evaluator.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export function evaluateLater(...args) {
2828
return theEvaluatorFunction(...args)
2929
}
3030

31-
let theEvaluatorFunction = normalEvaluator
31+
let theEvaluatorFunction = () => {}
3232

3333
export function setEvaluator(newEvaluator) {
3434
theEvaluatorFunction = newEvaluator

0 commit comments

Comments
 (0)