npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@furo/precompiled

v2.7.0

Published

The @furo/precompiled is for those who want to use the furo componetnt directly in HTML. There is no build step needed. It is a convenient way to use the components to prototype some ideas or just play around with FBP without a complex installation proce

Downloads

17

Readme

@furo/precompiled

The @furo/precompiled is for those who want to use the furo componetnt directly in HTML. There is no build step needed. It is a convenient way to use the components to prototype some ideas or just play around with FBP without a complex installation procedure. When you know that your ideas work, transfer them 1:1 to a web component, so others can install, use and extend them.

Warning This package was created teach furo FBP and for creating our demo systems , so we can use and show our components in a HUGO generated page. Some of the files are very big at the moment, because they are not optimized yet.

Demo

Run npm run stard-cdn-sample to start the cdn based sample.

Installation

The version of this package represents the versioning of @furo/collection.

Note Keep in mind that you can not mix CDN , NPM and self builded variants of the installation.

CDN

You can use the components by refering to them via the CDN. This is good when your project is public and your server is slower then the CDN.

<script type="module" src="/config/init.js"></script>
<script type="module" src="https://cdn.jsdelivr.net/npm/@furo/[email protected]/dist/furo-fbp.js"></script>
<script type="module" src="https://cdn.jsdelivr.net/npm/@furo/[email protected]/dist/framework.js"></script>

<script type="module" src="https://cdn.jsdelivr.net/npm/@furo/[email protected]/dist/layout.js"></script>

NPM

When your clients are in a closed environment and can not reach the real internet, prefer this variant. All files are delivered from your servers.

npm i -S @furo/precompiled

Build by your self and using /dist

When you need some other components, which are not installable as precompiled versions. Or you want to add your own components or compositions, you can clone this repository and extend it by your own component, or the installed components.

Make sure that they are referenced by collection.js via a file that represents your package. You can also add it as an entry point in the rollup.config.js.

You can copy the /dist folder to your project or make it available for your projects on some other way. Do this by pushing them to npm or by serving them via your CDN.

This kind of installation is only one step away from a set up with open wc and working with web dev server, which do not need a build step during the development phase. Consider to switch to this variant if your project gains complexity.

Usage

To use the components you have to load the package where they reside in. You will notice, that some components have their own js file. This is because they are used from different packages and is needed to keep a clean dependeny tree. It is ok to load this components directly, when you do not need something other, or load the package where they reside. It has no side effect if load them twice. Your browser knows what it have to do.

<script type="module" src="/config/init.js"></script>
<script type="module" src="/node_modules/@furo/precompiled/dist/furo-fbp.js"></script>
<script type="module" src="/node_modules/@furo/precompiled/dist/framework.js"></script>

<script type="module" src="/node_modules/@furo/precompiled/dist/layout.js"></script>

The init file [optional]

When you want to use the data components you have to install the specs that you have gerated with furo. This is a good place to do it. Maybe you want to set the locales or install your translations too.

To load the init.js from your page, do the following in your index.html.

Load the init.js before you load the other packages. Because some of them are dependant to the settings you do in the init and some will switch to a default setup.

[index.html]

 <!-- init is needed because we use data components -->
  <script type="module" src="/config/init.js"></script>
  <script type="module" src="dist/furo-fbp.js"></script>

[/config/init.js]

import { Init, i18n,  Env } from '/dist/framework.js'
import {Types,Services} from "./data_environment.js";

/**
 * Register resource bundle i18n
 */
import { Translations } from './translations.js';
i18n.registerResBundle(Translations);

/**
 * Register the types and services which was generated by furo
 */
Init.registerApiTypes(Types);
Init.registerApiServices(Services);

/**
 * register the API prefix based on the APPROOT.
 * This information is used for furo-deep-link and furo-reverse-deep-link to resolve the api address.
 *
 * We use /api here, because we do not have a dedicated host like api.xxx.com for the api services
 * @type {string}
 */
Env.api.prefix = `/api`;
Init.applyCustomApiPrefixToServicesAndTypes(Env.api.prefix);


/**
 * Translate static messages in SPEC
 */
let locale = 'de_ch';
if (i18n.resbundle[Env.locale.toLowerCase().replace('-', '_')]) {
  locale = Env.locale.toLowerCase().replace('-', '_');
}
Init.translateStaticTypeMessages(locale);

Compatibility Table

compat

Package Structure

The packages structured and named like the modules from components.furo.pro. This module contains some additional files like DOMFBP.js which is needed when you want the fbp features on <body>.

Addtional files:

  • fixed-tooltip-display.js Tooltip display for pages which scrolls the hole page.
  • DOMFBP.js Append FPB to any dom node, even body
  • light-bulb.js A nice example component used in the docs
  • ui5DisplayRegistry.js A UI5 display registry for the dynamic type renderers.
  • ui5Icons.js The complete iconset, because we can not expose them individually (sorry)

collection.js

This file contains the full set of the precompiled package and is huge.

Elements

config.js

Furo config components

Elements

data.js

This package contains the furo data components.

Elements

Elements

Elements

Elements

doc-helper.js

Utils for the documentation system.

Elements

framework.js

This package contains the furo "framework" classes.

Classes

  • Env stores your environment data
  • furo.js Export bundle for all framework classes
  • i18n Base i18n class
  • iconset Icon set loader
  • Sys Set your locale
  • Init App init stuff
  • Theme Theming stuff

furo-fbp.js

The core furo FBP packages and classes. Read more on fbp.furo.pro

Elements

Elements

layout.js

Layout components. Sometimes it is hard to describe the elements with text. Just take a look at the demos and you will get the idea.

Elements

needs a furo spec to work

Elements

Elements

route.js

Furo routing components

Elements

Elements

util.js

A collection of utility elements.

Elements

ui5.js

Enterprise-flavored sugar on top of native APIs!

Compliant to SAP Fiori design language. Rich feature set. Includes all enterprise standards, such as accessibility, i18n, theming, etc

What is inside

For seamless integration into the Furo environment, we have slightly extended some UI5 components.

All not listed components can be obtained directly from SAP

Elements

Compositions