ragokan / solform Goto Github PK
View Code? Open in Web Editor NEWA form management library for SolidJS that is very lightweight and simple!
Home Page: https://www.npmjs.com/package/solform
A form management library for SolidJS that is very lightweight and simple!
Home Page: https://www.npmjs.com/package/solform
Though 1.0.4 import works
missing a closing /
return <input {...register("name")}>;
Can you example out how to use values
?
const values: any
'values' is declared but its value is never read.ts(6133)
Property 'values' does not exist on type '{ register: (key: "email" | "count") => { ref: (ref: SolFormElement) => SolFormElement; name: "email" | "count"; }; submit: (event?: Event | undefined) => Promise<...>; ... 5 more ...; getAllValues: () => { ...; }; }'.ts(2339)
Hey, the latest NPM package (1.0.3) is missing the code and type files.
I downgraded to 1.0.2 for now.
Hi, I'm using your library (thank you ๐), and I'm wondering what is lacking currently in terms of support for radio groups in forms? I would be willing to contribute a PR to add support.
like how to do this?
validators: {
email: [
requiredValidator("This field is required"),
emailValidator("Value should be email!"),
],
name,id,captcha:[
requiredValidator("This field is required")
],
can do currently:
const { register, submit, loading, getAllValues, getValue, setValue, errors, watch } =
createForm<{ email: string; name: string, password: string, id: string, captcha: boolean }>({
initialValues: {
},
validators: {
email: [
requiredValidator("This field is required"),
emailValidator("Value should be email!"),
],
name: [
requiredValidator("This field is required"),
],
id: [
requiredValidator("This field is required"),
],
password: [
requiredValidator("This field is required"),
],
captcha: [
requiredValidator("Solving captcha is required"),
]
},
Typescript compiler currently throws an error while using solform with the textarea tag. This fix simply requires to change the type definition of the SolFormElement as the actual functionality does not change.
Current
export declare type SolFormElement = HTMLInputElement | HTMLSelectElement;
Proposed change
export declare type SolFormElement = HTMLInputElement | HTMLSelectElement | HTMLTextAreaElement;
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.