open-index/open-npm huggingface dataset:
npm package: @musicbird/xml-parser
Description: MusicBird - XML Parser
Author: Fletcher Lind
Latest version: 2.0.0

# MusicBird - XML Parser

Converts XML document into a JSON tree.
Used as a part of a GPX (Guitar Pro 6+ format) files parser in the MusicBird ecosystem.

## Installation
```
yarn add @musicbird/xml-parser
``` 
or 
```
npm install @musicbird/xml-parser
```

## Usage

```ts
import {parseXml, NodeWrapper} from '@musicbird/xml-parser';

const xmlString = '<SOME XML DOCUMENT>';
const jsonTree: NodeWrapper = parseXml(mainFile, { 
    // options 
});
```

## Output Data Format
### Wrapper
```ts
interface NodeWrapper {
    root: Node;
}
```
### Node
```ts
interface Node {
    name: string;
    value: string;
    isSelfClosing: boolean;
    attrs: {
        [key: string]: string;
    };
    children: Node[];
}
```

## Config Format

```ts
export interface ParserConfig {
    doctypeKey?: string;
    tagKey?: string;
    attrsKey?: string;
    contentKey?: string;
    childrenKey?: string;
    rootKey?: string;
    normalize?: boolean;
    lowerCaseTagsContent?: boolean;
    lowerCaseTagsNames?: boolean;
}
```

### Default Config
```ts
export const DEFAULT_CONFIG: ParserConfig = {
    doctypeKey: 'doctype',
    rootKey: 'root',
    tagKey: 'name',
    attrsKey: 'attrs',
    contentKey: 'value',
    childrenKey: 'children',
    normalize: true,
    lowerCaseTagsContent: true,
    lowerCaseTagsNames: false
};

```

## Example
Source:
```xml
<?xml version="1.0" encoding="utf-8"?>
<Tree>
    <Text>Text</Text>
    <CDATA><![CDATA[Text]]></CDATA>
    <Empty></Empty>
    <SelfClosing/>
    <TagWithAttrs
        id="0"
        ref="test-ref-value"
        test-attr="test-attr-value">
    </TagWithAttrs>
    <TagSequence>1</TagSequence>
    <TagSequence>2</TagSequence>
    <TagSequence>3</TagSequence>
</Tree>
```
Output:
```json
{
  "root": {
    "name": "Tree",
    "children": [
      {
        "name": "Text",
        "value": "text"
      },
      {
        "name": "CDATA",
        "value": "Text"
      },
      {
        "name": "Empty"
      },
      {
        "name": "SelfClosing",
        "isSelfClosing": true
      },
      {
        "name": "TagWithAttrs",
        "attrs": {
          "id": "0",
          "ref": "test-ref-value",
          "test-attr": "test-attr-value"
        }
      },
      {
        "name": "TagSequence",
        "value": "1"
      },
      {
        "name": "TagSequence",
        "value": "2"
      },
      {
        "name": "TagSequence",
        "value": "3"
      }
    ]
  }
}
```

## Dependencies
Uses [sax](https://www.npmjs.com/package/sax) to parse xml

## Changelog
**2.0.0**
- Parser now keeps tags names as is by default (doesn't lowercase it)
- Exported ```parser``` method was renamed with ```parseXml```
- A license changed to MIT
npm package: @musicca/extractors
Description: A collection of extractors for Musicca
Author: Edqe_
Latest version: 1.1.2

<div align="center">
  <img src="https://user-images.githubusercontent.com/34704796/147868696-bf61c114-7b94-41fe-8421-fc9b39c094ba.png" alt="Logo">

  <div>
    <img alt="GitHub" src="https://img.shields.io/github/license/musiccajs/extractors">
    <img alt="npm" src="https://img.shields.io/npm/dt/@musicca/extractors">
    <img alt="GitHub issues" src="https://img.shields.io/github/issues/musiccajs/extractors">
  </div>
</div>

# About 📛

This package is a collection of extractors for [Musicca](https://www.npmjs.com/package/musicca).

# Installation 💾

```sh-session
npm install @musicca/extractors
yarn add @musicca/extractors
pnpm add @musicca/extractors
```

# Links 🔗

- [Website](https://musicca.edqe.me) ([source](https://github.com/musiccajs/website))
- [Documentation](https://musicca.edqe.me/docs)
- [Github](https://github.com/musiccajs/extractors)
- [npm](https://www.npmjs.com/package/@musicca/extractors)
npm package: @musicca/structs
Description: A collection of structures for Musicca
Author: Edqe_
Latest version: 1.0.3
Deprecated: Discontinue support for @musicca/structs due to overheads. Read more: https://github.com/musiccajs/musicca/issues/14

<div align="center">
  <img src="https://user-images.githubusercontent.com/34704796/147868696-bf61c114-7b94-41fe-8421-fc9b39c094ba.png" alt="Logo">

  <div>
    <img alt="GitHub" src="https://img.shields.io/github/license/musiccajs/musicca">
    <img alt="npm" src="https://img.shields.io/npm/dt/musicca">
    <img alt="GitHub issues" src="https://img.shields.io/github/issues/musiccajs/musicca">
  </div>
</div>

# About 📛

This package is a collection of structures for [Musicca](https://www.npmjs.com/package/musicca).

# Installation 💾

```sh-session
npm install @musicca/structs
yarn add @musicca/structs
pnpm add @musicca/structs
```

# Guide 🖋

## Creating custom queue

First, you need to create a new queue class with your custom implementation

```ts
import { Queue, Media } from 'musicca';

export default class CustomQueue extends Queue {
  public list: Media[] = [];

  // Always put options at the 3rd parameter
  constructor(manager, id, options) { ... }

  // All custom methods are awaitable by default
  public all() { ... }
  public add<T extends Media | Media[] = Media>(media: T, position?: number) { ... }
  public get(position: number) { ... }
  public remove(position: number) { ... }
  public clear() { ... }
  public indexOf(media: Media) { ... }
}
```

Now, you can just plug it in to musicca

```ts
const client = new Musicca<CustomQueue>({
  plugins: { ... },
  structs: {
    queue: CustomQueue
  }
});
```

# Links 🔗

- [Website](https://musicca.edqe.me) ([source](https://github.com/musiccajs/website))
- [Documentation](https://musicca.edqe.me/docs)
- [Github](https://github.com/musiccajs/structs)
- [npm](https://www.npmjs.com/package/@musicca/structs)
npm package: @musicdr1ven/react-page-editor
Description: This is ReactPage's main Component.
Author: Marco Wettstein
Latest version: 0.2.2

# React-Page Editor

This is ReactPage's main Component.

Read the full readme here https://github.com/react-page/react-page

Docs: https://react-page.github.io/docs

Demo: https://react-page.github.io/
npm package: @musicflowai/cli
Description: Command-line client for the MusicFlow agent API
Latest version: 0.1.3

# MusicFlow CLI

`@musicflowai/cli` is the command-line client for the MusicFlow agent API. It is designed to be small, scriptable, and safe to automate against. The CLI talks only to the public v1 API and stores local auth state in `~/.config/musicflow/config.json`.

## Install

```bash
npm install @musicflowai/cli
```

Global install is also supported:

```bash
npm install -g @musicflowai/cli
```

## Authentication

There are two ways to authenticate.

### Interactive login

Use `musicflow login` to open a browser-based login flow. After you approve the request, the CLI stores a local app-managed API key and reuses it for future requests.

```bash
musicflow login
```

### API key

Set `MUSICFLOW_API_KEY` for non-interactive use:

```bash
export MUSICFLOW_API_KEY=mf_xxxxxxxxxxxxxxxxxxxx
```

By default, the CLI talks to the production API at `https://api.musicflowai.com`. Override the API base URL only if you are testing against a local or alternate environment:

```bash
export MUSICFLOW_APP_URL=https://api.musicflowai.com
```

## Commands

- `musicflow login`
- `musicflow logout`
- `musicflow whoami`
- `musicflow account`
- `musicflow auth status`
- `musicflow capabilities`
- `musicflow song create`
- `musicflow video from-song`
- `musicflow publish create`
- `musicflow plan create`
- `musicflow job get`

## Examples

Create a song draft:

```bash
musicflow song create \
  --prompt "Write a reflective indie song about starting over" \
  --producer-id 7d6b7b2a-7f1d-4f6d-bf4e-66ff5d9f0f4a \
  --generate-audio
```

Create a song and wait for audio completion:

```bash
musicflow song create \
  --prompt "Write a reflective indie song about starting over" \
  --generate-audio \
  --sync
```

Create a single video from a song:

```bash
musicflow video from-song \
  --song-id 6c4ab1b7-b8b4-4c1f-9c8f-4c33b0ed7a83 \
  --caption-mode auto \
  --caption-style alexHormozi \
  --aspect-ratio 9:16
```

Publish an existing video:

```bash
musicflow publish create \
  --content-id 0d7df30d-4f42-4db5-b00d-43d48f8dc2f7 \
  --youtube-channel-id 0b5b8ad0-4c6f-4b9f-8f08-dfe4e5f0f2d2 \
  --privacy-status unlisted
```

Inspect a queued job:

```bash
musicflow job get --id render:4e6c6fd2-1ad4-4b89-8145-21c64f2c3e19
```

## Development

This package is authored in `src/` and built to `dist/`.

```bash
cd packages/musicflow-cli
npm install
npm run build
```

For iterative development:

```bash
npm run dev -- song create --prompt "..."
```

If you want to lint or type-check the package only:

```bash
npm run check
```

## Release Notes

### 0.1.3

- Changed the default API host to `https://api.musicflowai.com`.
- Removed the localhost fallback from the published CLI default configuration.

### 0.1.0

- Initial standalone package extraction.
- Added browser-based login.
- Added support for `whoami`, `capabilities`, song creation, video creation, publishing, plan creation, and job polling.
- Switched published entrypoint to `dist/cli.js`.
npm package: @musicglue/async-hook
Description: Inspect the life of handle objects in node
Author: Andreas Madsen
Latest version: 1.3.3

#async-hook

> Inspect the life of handle objects in node

## Documentation

This is high level abstraction of the currently undocumented node API called
AsyncWrap. It patches some issues, makes the API more uniform and allows multiply
hooks to be created.

I personally hope that most of this will make it into nodecore, but for now
it exists as an userland module.

For the details of how AsyncWrap works and by extension how this module works,
please see the semi-official AsyncWrap documentation:
https://github.com/nodejs/tracing-wg/blob/master/docs/AsyncWrap/README.md

```javascript
const asyncHook = require('async-hook');
```

#### Hooks

The function arguments are:

```javascript
function init(uid, handle, provider, parentUid, parentHandle) { /* your code */ }
function pre(uid, handle) {  /* your code */ }
function post(uid, handle) {  /* your code */ }
function destroy(uid) {  /* your code */ }
```

To add hooks:

```javascript
asyncHook.addHooks({ init, pre, post, destroy });
```

To remove hooks:

```javascript
asyncHooks.removeHooks({ init, pre, post, destroy });
```

All properties in the hooks object that `addHooks` and `removeHooks` takes are
optional.

#### Providers

The providers map is exposed as:
```
asyncHook.providers[provider];
```

#### Enable and disable

You can enable and disable all hooks by using `asyncHook.enable()` and
`asyncHook.disable()`. By default it is disabled.

Be careful about disabling the hooks, this will most likely conflict with other
modules that uses `async-hook`.
npm package: @musicglue/dragon-tree
Description: A drag and drop tree component
Author: SteveParrington
Latest version: 1.2.1

# dragon-tree

> A drag and drop tree component

[![NPM](https://img.shields.io/npm/v/dragon-tree.svg)](https://www.npmjs.com/package/dragon-tree) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)

## Install

```bash
npm install --save dragon-tree
```

## Usage

```jsx
import React, { Component } from 'react'

import MyComponent from 'dragon-tree'
import 'dragon-tree/dist/index.css'

class Example extends Component {
  render() {
    return <MyComponent />
  }
}
```

## License

MIT © [SteveParrington](https://github.com/SteveParrington)
npm package: @musicglue/joi-ts-generator
Description: Generate Typescript Types from Joi schemas
Author: Music Glue
Latest version: 6.0.2
Deprecated: Package no longer maintained

# joi-ts-generator

Generate Typescript Types from Joi Schemae

### Installing

```
yarn add --dev @musicglue/joi-ts-generator
```

Then you should add a script to your package json that you can use to regenerate your types,
such as the following:

```json
{
  "scripts": {
    "regenerate-joi-types": "joi-ts-gen"
  },
  "joiTsGenerator": {
    "input": "./src/schemas/index.ts",
    "outputs": {
      "types": "./src/schemas/types.ts",
      "utils": "./src/schemas/utils.ts"
    }
  }
}
```

You can then rebuild your types by running `yarn regenerate-joi-types`.

### Defining

If you define Joi schemae that look like the following:

```ts
import joi = require("joi");

export const Country = joi.string().notes("type:Country");
export const Currency = joi.string().notes("type:Currency");
export const Package = joi.string().valid(["gold", "silver", "bronze"]).notes("type:Package");

export const Purchase = joi.object().keys({
  id: joi.string().guid().required(),
  country: Country,
  currency: Currency.required(),
  cents: joi.number().required(),
  notes: joi.array().items(joi.string()),
  package: Package.required(),
}).notes("type:Purchase");
```

Then this project will generate you Typescript typings as follows:

```ts
export type Uuid = string;
export type Country = string;
export type Currency = string;
export type Package = "gold" | "silver" | "bronze";

export interface Purchase {
  id: Uuid;
  country?: Country;
  currency: Currency;
  cents: number;
  notes?: string[];
  package: Package;
}
```

### Troubleshooting

If you are defining string types and find that you get unexpected results, please follow the following:

```ts
import * as joi from "joi";
import cloneSchema from "@musicglue/joi-ts-generator"

export const Country = cloneSchema(joi.string());
export const Currency = cloneSchema(joi.string());
```

This prevents our internals from overwriting themselves as we parse the schemae. Joi objects are immutable,
other than the entrypoint...