open-index/open-npm huggingface dataset:
npm package: @puresamari/spb-core
Description: A simple build tool for quick website development.
Author: Simon Rothert
Latest version: 0.2.5

# Simple Page Builder

[![npm version](https://badge.fury.io/js/%40puresamari%2Fspb-core.svg)](https://badge.fury.io/js/%40puresamari%2Fspb-core)

`SPB` is a really simple build tool, designed to just take input fields and automatically generate files without the hassle of creating a bloated config file.

## Supported files
At the moment, `spb` supports the compilation of `.ts`, `.css`, `.scss`, `.js`, `.twig` and `.pug` files. All other file types defined will just be copied when `watching` or `building` and served when using the `dev-server`. Images will automatically converted to the correct mime type as well.

# CLI

You can find the cli on [npm](https://www.npmjs.com/package/@puresamari/spb).

# Links

- [Changelog](https://github.com/puresamari/spb/blob/master/CHANGELOG.md)
npm package: @puresamari/spb-dev-server
Description: A simple build tool for quick website development.
Author: Simon Rothert
Latest version: 0.1.6

# Simple Page Builder

[![npm version](https://badge.fury.io/js/%40puresamari%2Fspb-dev-server.svg)](https://badge.fury.io/js/%40puresamari%2Fspb-dev-server)

`SPB` is a really simple build tool, designed to just take input fields and automatically generate files without the hassle of creating a bloated config file.

## Supported files
At the moment, `spb` supports the compilation of `.ts`, `.css`, `.scss`, `.js`, `.twig` and `.pug` files. All other file types defined will just be copied when `watching` or `building` and served when using the `dev-server`. Images will automatically converted to the correct mime type as well.

# CLI

You can find the cli on [npm](https://www.npmjs.com/package/@puresamari/spb).

# Links

- [Changelog](https://github.com/puresamari/spb/blob/master/CHANGELOG.md)
npm package: @puresamari/ts-bundler
Description: Simple typescript bundler
Author: Simon Rothert
Latest version: 0.3.5

# TS-Bundler

This is a **(super)** lightweight typescript bundle library, which I created for my build tool [@puresamari/spb]([https://](https://www.npmjs.com/package/@puresamari/spb)) since webpack creates way too much overhead.

# Installation

`npm i[nstall] [--save[-dev]|-D|-S] @puresamari/ts-bundler`

# Usage

```ts
import { TypescriptBundler } from '@puresamari/ts-bundler';

...

// Create the bundler with the file as attribute (file has to be an absolute path)
const bundler = new TypescriptBundler(file);
```

The bundlers observe method returns a rxjs observable that contains the following values:

```ts
interface {
  output: string,
  map: Map<string, {
    content: string;
    node_module: boolean;
    file: string;
    absolutePath: string;
  }>
}
```

The observe method takes 2 oparameters:
- Rebundle: should the bundle be compiled when running observe() (default = true)
- Once, should you only get the first trigger. (default = false)


## Example use cases
(To run these please first create a bundler instance like above.)

The examples compile file into `test.export.js`.

### Bundle the module:
```ts
import fs from 'fs';

const result = bundler.observe().subscribe(({ output }) => {
  fs.writeFileSync(path.resolve(__dirname, 'test.export.js'), v.output);
});
```

### The same but with file watching and module replacement:
```ts
import fs from 'fs';

const result = bundler.observe().subscribe(({ output }) => {
  fs.writeFileSync(path.resolve(__dirname, 'test.export.js'), v.output);
});

bundler.observe(false, true).subscribe(v => {
  v.map.forEach((v, _module) => {
    if (!v?.file || v.node_module) { return; }
    fs.watchFile(v.absolutePath, () => {
      bundler.refreshModule(_module);
    })
  })
});

```

### Bundle once using await:
```ts
import fs from 'fs';

fs.writeFileSync(path.resolve(__dirname, 'test.export.js'), await bundle.bundle().output);
```

### Bundle once using promise:
```ts
import fs from 'fs';

bundle.bundle().then(({ output }) => fs.writeFileSync(path.resolve(__dirname, 'test.export.js'), output);
```
npm package: @purescript/affjax
Description: An asynchronous AJAX library built using Aff.
Latest version: 4.0.0

# purescript-affjax

[![Latest release](http://img.shields.io/github/release/slamdata/purescript-affjax.svg)](https://github.com/slamdata/purescript-affjax/releases)
[![Build status](https://travis-ci.org/slamdata/purescript-affjax.svg?branch=master)](https://travis-ci.org/slamdata/purescript-affjax)

A library taking advantage of [`purescript-aff`](https://github.com/slamdata/purescript-aff) to enable pain-free asynchronous AJAX requests and response handling.

# Getting Started

## Installation

```
bower install purescript-affjax
```

If you are intending to use the library in a Node.js setting rather than the browser, you will need an additional dependency from `npm`:

```
npm install xhr2
```

## Introduction

You can construct requests with the `affjax` function:

```purescript
module Main where

import Prelude
import Control.Monad.Eff.Console (log)
import Control.Monad.Eff.Class (liftEff)
import Control.Monad.Aff (launchAff)
import Data.Either (Either(..))
import Data.HTTP.Method (Method(..))
import Network.HTTP.Affjax (affjax, defaultRequest)

main = launchAff $ do
  res <- affjax $ defaultRequest { url = "/api", method = Left GET }
  liftEff $ log $ "GET /api response: " <> res.response
```

(`defaultRequest` is a record value that has all the required fields pre-set for convenient overriding when making a request.)

Or use of a number of helpers for common cases:

```purescript
import Network.HTTP.Affjax (get, post)

main = launchAff $ do
  res1 <- get "/api"
  liftEff $ log $ "GET /api response: " <> res1.response

  res2 <- post "/api" someData
  liftEff $ log $ "POST /api response: " <> res2.response
```

See the module documentation for a full list of these helpers.

When sending data in a request the Requestable class enables automatic conversion into a format that is acceptable for an XHR request. Correspondingly there is a Respondable class for reading data that comes back from the server.

## Module documentation

Module documentation is [published on Pursuit](http://pursuit.purescript.org/packages/purescript-affjax).