thai-date-picker
v1.0.11
Published
this package was created for using Buddhist Era calendar. whatever component in side this we use andt so you can use documents from andt for every props
Downloads
6
Readme
introduction
this package was created for using Buddhist Era calendar. whatever component in side this we use andt so you can use documents from andt for every props
props must pass
lang -> have to pass 'th' for use Buddhist Era if the thers we set to be Christian Era onChange => pass function to get return of data ["2024-03-11T17:00:00.000Z", 12-03-2567] cellSelectedColor => pass string color
Usage/Examples
**before use package should create type.d.ts declare module 'thai-date-picker';
import { DatePickerCustom } from 'thai-date-picker';
const selectedDate = (date: any, dateString: string) => {
console.log('date in main', date, dateString);
return dateString;
};
function App() {
return (
<DatePickerCustom
onChange={selectedDate}
lang="th"
cellSelectedColor="#006400"
/>
);
}