React + TypeScript + Vite app for a browser-based diabetes prediction demo powered by a BigML decision tree.
- React 19
- TypeScript
- Vite
- Tailwind CSS
- shadcn/ui-style reusable components
npm install
npm run devnpm run buildThe app reads the model directly from Decision tree - code from BigML.txt and evaluates the exported nested if/else tree in the browser.
The public helper remains predictDiabetes(data), so the UI stays unchanged even if you swap in a new export later.
src/App.tsx: page layout, form state, submit handlingsrc/components/: UI primitives and reusable form fieldsrc/data/diabetes-fields.ts: field metadata and biological rangessrc/lib/validation.ts: parsing and input validationsrc/lib/predict-diabetes.ts: parser and evaluator for the BigML decision tree export
This repository now includes .github/workflows/deploy.yml for automatic GitHub Pages deployment.
- Open the repository on GitHub.
- Go to
Settings -> Pages. - Under
Build and deployment, setSourcetoGitHub Actions. - Push to
mainand GitHub will build and publish thedistfolder automatically.
Your Pages URL should be:
https://tom-kroupa.github.io/diabetesdatamining/
If you prefer a simpler UI and automatic preview URLs on every push:
- Import the GitHub repository into Vercel or Netlify.
- Keep the default Vite build settings (
npm run build, outputdist). - Each new push to GitHub will trigger a deployment automatically.
The current repository includes the pasted BigML export file and evaluates that logic client-side.