baked_file_handler

baked_file_handler

A Kemal handler for serving files baked into the application.

Installation

  1. Add the dependency to your shard.yml:

    dependencies:
      baked_file_handler:
        github: ralsina/baked_file_handler
    
  2. Run shards install

Usage

require "kemal"
require "baked_file_system"

# Example BakedFileSystem class
class MyAssets
  extend BakedFileSystem
  bake_folder "./public_assets"
end

add_handler BakedFileHandler::BakedFileHandler.new(MyAssets)

Kemal.run

Development

I don't expect this need much further development. In any case, it's simple enough code :-)

Contributing

  1. Fork it (https://github.com/ralsina/baked_file_handler/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors

Repository

baked_file_handler

Owner
Statistic
  • 0
  • 0
  • 0
  • 1
  • 0
  • 1 day ago
  • June 7, 2025
License

MIT License

Links
Synced at

Wed, 18 Jun 2025 00:39:38 GMT

Languages