open-index/open-npm huggingface dataset:
npm package: @matthiasn/draftjs-md-converter
Description: Converter for converting Draft.js state into Markdown and vice versa
Author: Kadi Kraman
Latest version: 1.2.0-4

[![npm version](https://badge.fury.io/js/draftjs-md-converter.svg)](https://badge.fury.io/js/draftjs-md-converter)

# Draft.js to Markdown to Draft.js converter

Converts rich text content between Draft.js blocks and Markdown.

## Reasoning and background

This library exists because I needed a highly customisable rich text editor which posts to an external API in Markdown. [Draft.js](https://facebook.github.io/draft-js/) to the rescue! It provides the editor state but, alas, doesn't ship with any sort of conversion to or from markdown. So, I've written my own.

## Installation

```
npm install draftjs-md-converter
```

## Support

The following inline styles are supported:

* bold
* italic
* H1 - H6

The following block styles are supported:

* ordered list
* unordered list
* block quote

The following media types are supported:

* images
* videos (with draft-js-video-plugin, parsing can be done using remark-shortcodes)

## Usage

### Converting from Markdown to Draft.js
### `mdToDraftjs(markdown: String): RawDraftContentState`

Use [convertToRaw](https://facebook.github.io/draft-js/docs/api-reference-data-conversion.html) from the `draft-js library` to convert the resulting RawDraftContentState into a draft-js ContentState.

### Converting from Draft.js to Markdown
### `draftjsToMd(rawData: RawDraftContentState): String`

Use [convertFromRaw](https://facebook.github.io/draft-js/docs/api-reference-data-conversion.html) from the `draft-js library` to get the raw RawDraftContentState to then pass into the converter.

### Custom dictionaries

The default Markdown dictionary is

```js
{
  BOLD: '**',
  ITALIC: '*'
};
```

The inline styles can be extended or overridden by passing a custom dictionary object as a second optional argument to `draftjsToMd`, e.g.

```js
const myMdDict = {
  BOLD: '**',
  STRIKETHROUGH: '~~'
};
const markdown = draftjsToMd(blocks, myMdDict);
```

__NOTE: at this point you cannot override block styles!__

## Example

```js
[---]

import { mdToDraftjs, draftjsToMd } from 'draftjs-md-converter';
import { EditorState, ContentState, convertToRaw, convertFromRaw } from 'draft-js';

[---]

constructor(props) {
  super(props);

  // some default value in markdown
  const defaultValue = this.props.defaultValue;
  const rawData = mdToDraftjs(defaultValue);
  const contentState = convertFromRaw(rawData);
  const newEditorState = EditorState.createWithContent(contentState);

  this.state = {
    editorState: newEditorState,
  };
  this.onChange = (editorState) => {
    this.props.onChange(this.getMarkdown());
    this.setState({ editorState });
  };
}

[---]

getMarkdown() {
  const content = this.state.editorState.getCurrentContent();
  return draftjsToMd(convertToRaw(content));
}

[---]
```

## Run tests

```
npm test
```

## Run tests with a watcher

```
npm run test-dev
```

## Lint

```
npm run lint
```
npm package: @matthiasn/graphql-transport-electron
Description: Enables inter process communication between a graphql client & server in electron.
Author: Sebastian Siemssen
Latest version: 1.0.5-1

# graphql-transport-electron

## Why

In case you want to run a graphql server inside of the Electron main process (for instance
if you are building a decentralized application), you need to have the client (renderer process)
and server (main process) communicate through Electron IPC.

This project provides a very lightweight client and server interface for Electron IPC based on
Apollo.

While its primary use-case is to enable a self-sustained and isolated graphql server inside of
the Electron main process, you can connect the server interface to any ApolloLink instance.
This means that you could also connect it with a HttpLink / WsLink that forwards your queries
to a hosted graphql server outside of Electron.

## Installation

```
# With yarn
yarn add graphql-transport-electron

# With npm
npm install graphql-transport-electron
```

## Usage example

### Main process

```typescript
import { ipcMain } from 'electron';
// NOTE: The library ships with a fork of apollo-link-schema that also supports subscriptions.
import { createSchemaLink, createIpcExecutor } from 'graphql-transport-electron';
import schema from './my-graphql-schema';

// NOTE: This also works with any other apollo link (e.g. HttpLink from apollo-link).
const link = createSchemaLink({ schema });
createIpcExecutor({link, ipc: ipcMain });
```

### Renderer process

```typescript
import { ApolloClient } from 'apollo-client';
import { InMemoryCache } from 'apollo-cache-inmemory';
import { ipcRenderer } from 'electron';
import { createIpcLink } from 'graphql-transport-electron';

const link = createIpcLink({ ipc: ipcRenderer });
const client = new ApolloClient({
  cache: new InMemoryCache(),
  link,
});

```
npm package: @matthid/source-map-visualization
Description: Initial idea from https://github.com/sokra/source-map-visualization
Author: Matthias Dittrich @matthid
Latest version: 0.5.0

# Source Map Visualizer

Initial idea from https://github.com/sokra/source-map-visualization

This app allows to debug and visualize source maps.

## Install pre-requisites

You'll need to install the following pre-requisites in order to build the Source Map Visualizer

* The [.NET Core SDK](https://www.microsoft.com/net/download)
* [FAKE 5](https://fake.build/) installed as a [global tool](https://fake.build/fake-gettingstarted.html#Install-FAKE)
* The [Yarn](https://yarnpkg.com/lang/en/docs/install/) package manager (you can also use `npm` but the usage of `yarn` is encouraged).
* [Node LTS](https://nodejs.org/en/download/) installed for the front end components.
* If you're running on OSX or Linux, you'll also need to install [Mono](https://www.mono-project.com/docs/getting-started/install/).

## Build and Run (Development)

Start Server (including client)

```
yarn client-build
yarn server-build
cd src/Server
node deploy/app.<hash>.js
```

Start Client (hot module reloading, needs a started server)

```
yarn client-start
```


## Work with the application

To concurrently run the server and the client components in watch mode use the following command:

```bash
fake build -t Run
```


## SAFE Stack Documentation

You will find more documentation about the used F# components at the following places:

* [Giraffe](https://github.com/giraffe-fsharp/Giraffe/blob/master/DOCUMENTATION.md)
* [Fable](https://fable.io/docs/)
* [Elmish](https://elmish.github.io/elmish/)
* [Fulma](https://fulma.github.io/Fulma/)

If you want to know more about the full Azure Stack and all of it's components (including Azure) visit the official [SAFE documentation](https://safe-stack.github.io/docs/).

## Troubleshooting

* **fake not found** - If you fail to execute `fake` from command line after installing it as a global tool, you might need to add it to your `PATH` manually: (e.g. `export PATH="$HOME/.dotnet/tools:$PATH"` on unix) - [related GitHub issue](https://github.com/dotnet/cli/issues/9321)
npm package: @matthiebl/npm-tailwind-template
Description: A template npm module with react + typescript + tailwindcss
Author: Matthew Hiebl
Latest version: 0.1.5

# @matthiebl/npm-tailwind-template

This is a simple template repo for making an npm module with react + typescript + tailwind

## Setup

This is the folder structure we set up for you:

```txt
/src
  index.tsx       # This is where all built exports will be available from
  /stories        # Where stories for storybook are located
    ...
/test             # Where tests are located
  ...
.gitignore
package.json
README.md         # EDIT THIS
tsconfig.json
```

You will need to rename the `name` of the package in the `package.json`. I recommend find and replace `npm-tailwind-template` with `<your package name>`. Ensure the author, license, homepage, bugs, and repository are all correct as well.
npm package: @matthiesenxyz/astrodtsbuilder
Description: A utility function is used to build declaration files for use with Astro's `injectTypes` function added in the `astro:config:done` Integration Hook in `Astro 4.14.0`.
Author: Adam Matthiesen
Latest version: 0.2.0
Deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

# Build a declaration file for Astro Integrations

This utility function is used to build a declaration file for use with Astro's `injectTypes` function added in the `astro:config:done` Integration Hook in `Astro 4.14.0`. This function is useful for generating TypeScript declaration files for Astro Integrations.

## Example Usage

```ts
// Import and use the function
import buildDeclarationFile from '@matthiesenxyz/astrodtsbuilder';
const dts = buildDeclarationFile();

// Add a note to the file
dts.addSingleLineNote(`This file was generated by '@my-example/module'`);

// Add a Multi-line Note to the file
dts.addMultiLineNote(['It does some cool and helpful stuff', 'It also does some other cool stuff']);

// Add a module with a default export and single line description
dts.addModule("example:module", {
  defaultExport: {
    typeDef: "import('@my-example/module').ExampleModule",
    singleLineDescription: "This is the default Module",
  }
});

// Write the file
const dtsFile = dts.makeFile();

// Output the file
console.log(dtsFile);
```

## Example Output

```ts
// This file was generated by '@my-example/module'

// It does some cool and helpful stuff
// It also does some other cool stuff

declare module 'example:module' {
    //** This is the default Module * /
    const defaultExport: import('@my-example/module').ExampleModule;
    export default defaultExport;

}
```

## Licensing

[MIT Licensed](./LICENSE). Made with ❤️ by [Adam Matthiesen](https://github.com/adammatthiesen).
npm package: @matthiesenxyz/unocss-preset-daisyui
Description: UnoCSS preset for daisyUI based on kidonng/unocss-preset-daisy
Author: Adam Matthiesen
Latest version: 0.1.2
Deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

# unocss-preset-daisy

> [UnoCSS](https://github.com/unocss/unocss) preset for [daisyUI](https://github.com/saadeghi/daisyui)

[Checkout the demo!](https://unocss-preset-daisy.vercel.app/)

## Installation

```sh
npm install unocss daisyui @mattheisenxyz/unocss-preset-daisyui
```

## Usage

> **Note**: `@unocss/reset` comes with `unocss`. If you are using pnpm, install it separately unless you enable hoisting.

### Vite

```js
import {defineConfig} from 'vite'
import unocss from 'unocss/vite'
import {presetUno} from 'unocss'
import {presetDaisy} from '@mattheisenxyz/unocss-preset-daisyui'

export default defineConfig({
	plugins: [
		unocss({
			presets: [presetUno(), presetDaisy()],
		}),
	],
})
```

```js
import '@unocss/reset/tailwind.css'
import 'uno.css'
```

### Astro

```js
import {defineConfig} from 'astro/config'
import unocss from 'unocss/astro'
import {presetUno} from 'unocss'
import {presetDaisy} from '@mattheisenxyz/unocss-preset-daisyui'

export default defineConfig({
	integrations: [
		unocss({
			presets: [presetUno(), presetDaisy()],
			injectReset: true,
		}),
	],
})
```

### Nuxt

To use UnoCSS with Nuxt, `@unocss/nuxt` must be installed as well.

```js
import {defineNuxtConfig} from 'nuxt/config'
import {presetUno} from 'unocss'
import {presetDaisy} from '@mattheisenxyz/unocss-preset-daisyui'

export default defineNuxtConfig({
	modules: ['@unocss/nuxt'],
	css: ['@unocss/reset/tailwind.css'],
	unocss: {
		presets: [presetUno(), presetDaisy()],
	},
})
```

## Config

This preset accepts [the same config as daisyUI](https://daisyui.com/docs/config/) (except for `logs` and `prefix`).

```js
{
	presets: [
		presetUno(),
		presetDaisy({
			styled: false,
			themes: ['light', 'dark'],
		}),
	],
}
```

## Limitations

**This is not a full daisyUI port.** All daisyUI components/utilities should work but they may not work with some UnoCSS features:

- [#14](https://github.com/kidonng/unocss-preset-daisy/issues/14): [variants](https://windicss.org/utilities/general/variants.html) do not work

**Unused styles may be imported.** This is both due to lots of hacks being used and how UnoCSS works. However, the preset will try to figure out the minimum styles needed, thus the cost is trivial most of the time.
npm package: @matthieulemoine/clone-org
Description: Clone all the repositories of a given organization.
Author: MatthieuLemoine
Latest version: 1.0.0

# clone-org

Clone all the repositories of a given organization.

## Install

```
npm i -g @matthieulemoine/clone-org
# or
yarn global add @matthieulemoine/clone-org
```

## Usage

```
clone-org --token <githubPersonalAccessToken> --org <organizationName> --dir <targetDirectory>
```

:warning: Will not clone a repository if a folder with the same name already exists in `<targetDirectory>`.
npm package: @matthieulemoine/liner
Description: Show a specific line from a file.
Author: MatthieuLemoine
Latest version: 1.0.0

# Liner

Show a specific line from a file.

## Install

```
npm i -g @matthieulemoine/liner
```

## Usage

```
liner -l <lineNumber> -C <numberOfLinesToShow> <file>
```

## Options

* l : line to show (required)
* C : number of lines to show (optional)
npm package: @matthieulemoine/prisma-sequelize-generator
Description: Sequelize models generator for prisma schema
Author: Victor Korzunin
Latest version: 1.5.2

# 🏳️‍🌈⃤ Prisma Sequelize Generator

A generator, which takes a Prisma 2 `schema.prisma` and generates Sequelize Models.

[![Generic badge](https://img.shields.io/badge/Generator%20for-◭%20Prisma-9F7AEA.svg)](https://www.prisma.io)
[![npm version](https://img.shields.io/npm/v/prisma-sequelize-generator?label=npm%20package)](https://www.npmjs.com/package/prisma-sequelize-generator)
[![npm downloads](https://img.shields.io/npm/dm/prisma-sequelize-generator)](https://www.npmjs.com/package/prisma-sequelize-generator)
[![build status](https://img.shields.io/github/workflow/status/floydspace/prisma-sequelize-generator/release)](https://github.com/floydspace/prisma-sequelize-generator/actions/workflows/release.yml)
[![Code QL](https://github.com/floydspace/prisma-sequelize-generator/workflows/CodeQL/badge.svg)](https://github.com/floydspace/prisma-sequelize-generator/actions/workflows/codeql-analysis.yml)
[![Coverage Status](https://coveralls.io/repos/github/floydspace/prisma-sequelize-generator/badge.svg?branch=beta)](https://coveralls.io/github/floydspace/prisma-sequelize-generator?branch=beta)
[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)
[![GitHub license](https://img.shields.io/github/license/Naereen/StrapDown.js.svg)](https://github.com/floydspace/prisma-sequelize-generator/blob/master/LICENSE)

## Getting Started

### 1. Install

npm:

```shell
npm install prisma-sequelize-generator --save-dev
```

yarn:

```shell
yarn add -D prisma-sequelize-generator
```

### 2. Add the generator to the schema

```prisma
generator client {
  provider = "prisma-sequelize-generator"
}
```

With a custom output path (`./sequelize` - default)

```prisma
generator client {
  provider = "prisma-sequelize-generator"
  output = "custom-output-path"
}
```

Additional options

```prisma
generator client {
  provider = "prisma-sequelize-generator"
  outputFormat = "typescript"
}
```

Supported output formats are `javascript` (alias `js` - default) and `typescript` (alias `ts`).

### 3. Run generation

prisma:

```shell
prisma generate
```

### 3. Use Sequelize Models to interact with your database

```typescript
import { createSequelizeInstance } from './prisma/sequelize';

const { sequelize, models } = createSequelizeInstance({
  ssl: true,
  dialectOptions: {
    connectTimeout: 1000,
  },
});
// use `sequelize` instance and `models` in your application to read and write data in your DB
```

No need to set a connection string, it is set form the `datasource` configuration in your `schema.prisma` by default.

## Supported Node Versions

|         Node Version | Support            |
| -------------------: | :----------------- |
| (Maintenance LTS) 12 | :heavy_check_mark: |
|      (Active LTS) 14 | :heavy_check_mark: |
|         (Current) 16 | :heavy_check_mark: |