built_html 0.1.2

  • README.md
  • CHANGELOG.md
  • Installing
  • Versions
  • 76

A basic Builder for injecting content into html templates.

Usage

First, add a dependency on this package:

dev_dependencies:
  built_html: ^0.2.0

The next step is to rename your *.html files to a *.template.html files. Those files will be modified and copied to the original *.html location.

Also, take a look at example project for a working solution.

Commands

digest <url>

This command adds a content hash of an asset. Takes one parameter, the path to the file.

<script src="main.dart.js?q={{digest main.dart.js}}"></script>

version

This command simply adds the version from your package.yaml. Takes no parameters.

<script src="main.dart.js?q={{version}}"></script>

0.1.2

Clean up .template.html files by default in release mode. To disable you can configure the builder in your build.yaml:

targets:
  $default:
    builders:
      built_html|template_cleanup:
        release_options:
          enabled: false

0.1.1

Add support of version command.

0.1.0+1

Allow 2.0.0 of the sdk.

0.1.0

Initial release, supports {{digest <uri>}} tags in html.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  built_html: ^0.1.2

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter packages get

Alternatively, your editor might support pub get or flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:built_html/builder.dart';
  
Version Uploaded Documentation Archive
0.1.2 Aug 21, 2018 Go to the documentation of built_html 0.1.2 Download built_html 0.1.2 archive
0.1.1 Aug 21, 2018 Go to the documentation of built_html 0.1.1 Download built_html 0.1.1 archive
0.1.0+1 Aug 16, 2018 Go to the documentation of built_html 0.1.0+1 Download built_html 0.1.0+1 archive
0.1.0 Aug 16, 2018 Go to the documentation of built_html 0.1.0 Download built_html 0.1.0 archive
Popularity:
Describes how popular the package is relative to other packages. [more]
59
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
80
Overall:
Weighted score of the above. [more]
76
Learn more about scoring.

We analyzed this package on Sep 18, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0
  • pana: 0.12.3

Platforms

Detected platforms: Flutter, other

Platform components identified in package: build, io, isolate.

Suggestions

The description is too short.

Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0 <3.0.0
build ^0.12.5 0.12.7+3
yaml ^2.1.15 2.1.15
Transitive dependencies
analyzer 0.32.5 0.33.0-alpha.0
args 1.5.0
async 2.0.8
charcode 1.1.2
collection 1.14.11
convert 2.0.2
crypto 2.0.6
csslib 0.14.5
front_end 0.1.4+1 0.1.5
glob 1.1.7
html 0.13.3+3
kernel 0.3.4+1 0.3.5
logging 0.11.3+2
meta 1.1.6
package_config 1.0.5
path 1.6.2
plugin 0.2.0+3
source_span 1.4.1
string_scanner 1.0.4
typed_data 1.1.6
utf 0.9.0+5
watcher 0.9.7+10
Dev dependencies
build_test ^0.10.0
test ^1.0.0