Skip to content

Latest commit

 

History

68 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pola_barcodes

A Jaspr web application for displaying and managing barcodes used in the Pola project. The site is statically pre-rendered at build time and hydrated on the client.

Live app: https://klubjagiellonski.github.io/pola-barcodes/

Internationalization (i18n)

This project uses slang for internationalization. Translation source files are located in lib/i18n/ (e.g. en.i18n.json, pl.i18n.json).

The generated Dart file (lib/i18n/strings.g.dart) is not committed to the repository. It must be generated before building or running the app:

dart pub get
dart run slang

This project also uses json_serializable for JSON serialization. The generated file (lib/barcode_item.g.dart) is not committed to the repository and must also be generated:

dart run build_runner build --delete-conflicting-outputs

URL Paths

The app supports several URL paths that make it easy to share specific barcodes.

Predefined codes

You can share a predefined barcode by navigating to /code/{codeName}:

Custom codes

You can quickly create a custom barcode by using the EAN-13 or EAN-8 path:

Adding a description

You can also add a description to any code using the description query parameter:

Development

Requires the Dart SDK (>= 3.10) and the Jaspr CLI:

dart pub global activate jaspr_cli

Then:

dart pub get
dart run slang
dart run build_runner build --delete-conflicting-outputs
jaspr serve

The app is served at http://localhost:8080 with hot reload.

Building

dart pub get
dart run slang
jaspr build --dart-define=BASE_PATH=/pola-barcodes/

The static site is generated into build/jaspr/. The BASE_PATH define sets the <base href> for hosting under a sub-path (GitHub Pages project site); omit it when hosting at the domain root.

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages