BSD Ports

www/rubygem-importmap-rails 2.2.3 FreeBSD

Use ESM with importmap to manage modern JavaScript in Rails without transpiling or bundling

System
FreeBSD
Repository
FreeBSD ports
Maintainer
[email protected]
License
MIT
Categories
www, rubygems
Package size
18.5 KiB, 56.3 KiB installed

Description

Import maps let you import JavaScript modules using logical names that map to versioned/digested files -- directly from the browser. So you can build modern JavaScript applications using JavaScript libraries made for ESM without the need for transpiling or bundling.This frees you from needing Webpack, Yarn, npm, or any other part of the JavaScript toolchain. All you need is the asset pipeline that's already included in Rails.

With this approach you'll ship many small JavaScript files instead of one big JavaScript file. Thanks to HTTP/2 that no longer carries a material performance penalty during the initial transport, and in fact offers substantial benefits over the long run due to better caching dynamics. Whereas before any change to any JavaScript file included in your big bundle would invalidate the cache for the whole bundle, now only the cache for that single file is invalidated.

There's native support for import maps in Chrome/Edge 89+, and a shim available for any browser with basic ESM support. So your app will be able to work with all the evergreen browsers.

In the other systems

SystemPortVersion
FreeBSDwww/rubygem-importmap-rails2.2.3
DragonFlywww/rubygem-importmap-rails2.1.0_1

Install

Binary package:

pkg install rubygem-importmap-rails

From the ports tree:

cd /usr/ports/www/rubygem-importmap-rails/ && make install clean

To depend on this port in another port's Makefile:

RUN_DEPENDS=	rubygem-importmap-rails>0:www/rubygem-importmap-rails

Packages

The version each package repository carries. “-” means the repository builds no package of it, “n/a” that there is no such repository.

Repositoryaarch64amd64armv6armv7i386
FreeBSD:14:latest2.2.32.2.31.1.5-2.2.3
FreeBSD:14:quarterly2.2.32.2.3n/a-2.2.3
FreeBSD:15:latest2.2.32.2.3n/a-2.2.0
FreeBSD:15:quarterly2.2.32.2.3n/an/an/a
FreeBSD:16:latest2.2.32.2.3n/an/an/a
FreeBSD:16:quarterlyn/an/an/an/an/a

Dependencies

As this port's Makefile names them.

Runtime 3

The full lists below include those, and their dependencies in turn.

Build dependencies 6
Run dependencies 54

Configuration

No options to configure.

USES
gem
Service scripts
none

Files

distinfo 1
FileSizeSHA256
rubygem/importmap-rails-2.2.3.gem209927101be2a4dc97cf1558fb8f573a718404c5f6bcfe94f304bf1f39e444feeb16a
Master sites 1
  • RG

Commit history 0

No commits in the history this site was built from.