I have a file on my machine at /abc/assets/file/
I want to return this file as a route. It is possible to do that ?
I have a file on my machine at /abc/assets/file/
I want to return this file as a route. It is possible to do that ?
Copyright © 2021 Jogjafile Inc.
You would typically do that outside Dancer in your PSGI file with a different Plack application that's mounted in the same PSGI file. Have a look at Plack::App::File for an individual file, or Plack::App::Directory for an entire directory.
Your PSGI file would then look something like this.