aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2023-08-25 10:32:41 +0530
committerAkshay Nair <phenax5@gmail.com>2023-08-25 10:32:41 +0530
commit0bf85a7a812bef9eec097710f92c490c0ed9719a (patch)
treeafe6e9d1c4969d7b42466dcc3157e78b5c7785ac /examples
parent0665e6a2490c9ea770a98908788a1e5d210aa811 (diff)
downloadcss-everything-0bf85a7a812bef9eec097710f92c490c0ed9719a.tar.gz
css-everything-0bf85a7a812bef9eec097710f92c490c0ed9719a.zip
feat: scoped try error handling with error property
Diffstat (limited to '')
-rw-r--r--examples/form/signup.css5
1 files changed, 4 insertions, 1 deletions
diff --git a/examples/form/signup.css b/examples/form/signup.css
index 3433b87..3811c42 100644
--- a/examples/form/signup.css
+++ b/examples/form/signup.css
@@ -29,7 +29,10 @@
--cssx-on-submit:
prevent-default()
add-class(form, 'submitting')
- request('/examples/')
+ try(
+ request('https://jksldjflksdjlfsd.com/wow'),
+ js-eval(string('alert("', get-var(--error), '")'))
+ )
remove-class(form, 'submitting')
add-class(form, 'submitted')
;