Starter for an application with the Daton framework
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

26 lines
912 B

  1. #!/usr/bin/env -S deno run -c ./tsconfig.json --unstable --allow-read --allow-env --allow-net --importmap=./import-map.json --reload
  2. /* Main executable for the Daton app. */
  3. import { make, Scaffolding, Application } from './bundle/daton.ts'
  4. import units from './units.ts'
  5. /*
  6. * Let's get up and running. The scaffolding provides the bare minimum
  7. * amount of support required to get Daton up and running. The app handles
  8. * the rest.
  9. *
  10. * Daton will automatically load and process application resources, which is
  11. * why we need to pass in the base path of this script.
  12. */
  13. console.log('Import URL')
  14. console.log(import.meta.url)
  15. const scaffolding = make(Scaffolding, import.meta.url)
  16. await scaffolding.up()
  17. /*
  18. * Now, import the units and start the application. The units define each
  19. * modular piece of functionality that is managed by the Daton app.
  20. */
  21. const app = make(Application, units)
  22. await app.run()