Skip to content
This repository has been archived by the owner on Jul 17, 2024. It is now read-only.

promote initial v2.0.0 work in progress to main #8

Merged
merged 18 commits into from
Mar 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: CI
on: [push]
jobs:
build:
name: Build, lint, and test on Node ${{ matrix.node }} and ${{ matrix.os }}

runs-on: ${{ matrix.os }}
strategy:
matrix:
node: ['10.x', '12.x', '14.x']
os: [ubuntu-latest, windows-latest, macOS-latest]

steps:
- name: Checkout repo
uses: actions/checkout@v2

- name: Use Node ${{ matrix.node }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}

- name: Install deps and build (with cache)
uses: bahmutov/npm-install@v1

- name: Lint
run: yarn lint

- name: Test
run: yarn test --ci --coverage --maxWorkers=2

- name: Build
run: yarn build
12 changes: 12 additions & 0 deletions .github/workflows/size.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: size
on: [pull_request]
jobs:
size:
runs-on: ubuntu-latest
env:
CI_JOB_NUMBER: 1
steps:
- uses: actions/checkout@v1
- uses: andresz1/size-limit-action@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
12 changes: 12 additions & 0 deletions .github/workflows/telegram.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
on:
push

jobs:
notifyTelegram:
runs-on: ubuntu-latest
steps:
- name: Notify the commit on Telegram
uses: EverythingSuckz/github-telegram-notify@main
with:
bot_token: '${{ secrets.BOT_TOKEN }}'
chat_id: '${{ secrets.CHAT_ID }}'
39 changes: 4 additions & 35 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,36 +1,5 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
node_modules
.pnp
.pnp.js

# testing
coverage

# next.js
.next/
out/
build

# misc
*.log
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env
.env.local
.env.development.local
.env.test.local
.env.production.local

# turbo
.turbo

# vercel
.vercel
node_modules
.cache
dist
3 changes: 0 additions & 3 deletions .gitmodules

This file was deleted.

1 change: 0 additions & 1 deletion .npmrc

This file was deleted.

8 changes: 8 additions & 0 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
module.exports = {
stories: ['../stories/**/*.stories.@(ts|tsx|js|jsx)'],
addons: ['@storybook/addon-links', '@storybook/addon-essentials'],
// https://storybook.js.org/docs/react/configure/typescript#mainjs-configuration
typescript: {
check: true, // type-check stories during Storybook build
}
};
5 changes: 5 additions & 0 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
// https://storybook.js.org/docs/react/writing-stories/parameters#global-parameters
export const parameters = {
// https://storybook.js.org/docs/react/essentials/actions#automatically-matching-args
actions: { argTypesRegex: '^on.*' },
};
7 changes: 0 additions & 7 deletions .vscode/settings.json

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE.md → LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2023 Dylan Steck
Copyright (c) 2024 fuegoblanco

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
81 changes: 48 additions & 33 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,48 @@
# farcaster kit

![farcaster kit og:image](https://i.imgur.com/qajaZLU.png)

react hooks for the best farcaster apps -- [view docs](https://farcasterkit.com/docs)

farcaster kit is made up of two parts:
1. react hooks and modules to build the best farcaster apps
2. a rest api to fetch data with or without the hooks

### what's in the box?
- ✅ rest api
- ✅ read features
- ✅ channels module
- ✅ app-first feeds
- ✅ historic data
- ✅ user pages
- 🔜 auth hooks
- 🔜 write actions
- 🔜 multi package/provider support

### how this repo is structured
- `packages/farcasterkit` - react hooks and modules, which are available to install with `npm install farcasterkit`
- `packages/create-farcaster-app` - a CLI tool to scaffold an app using `npx create-farcaster-app`, which lives at `examples/starter`
- `apps/api` - the rest api for farcaster kit
- `apps/web` - the homepage and docs for farcaster kit, which you can [view here](https://farcasterkit.com)
- `apps/old-replicator` -- the postgres replicator powering farcaster kit, built by farcaster. a migration to the [new replicator](https://github.com/farcasterxyz/hub-monorepo/tree/main/apps/replicator) will happen soon!
- `examples/starter` - a starter app which you can scaffold by using `npx create-farcaster-app`
<br/>

built by [dylsteck](https://github.com/dylsteck) and powered by [nexus](https://withcortex.com)

----
# Farcasterkit

**A unified Typescript API for Farcaster Data**

You need to get Farcaster data and need to read all API documentations and even more. Farcasterkit solves this by offering a one stop library that exposes a unified API so you don't need to worry about different implementations (think viem/ethers.js providers but for Farcaster).

## Installation

```bash
npm install @dtechvision/farcasterkit
```

![use farcasterkit to get Farcaster Data easily using Typescript](logo.png)

## Ressources

- [NPM]- TODO
- [React Hooks] - SOON
- [Farcaster Channel] - Whut? wow!
- [Docs] - SOON, for now github Issues
- [Looking for Developers? / need Help?] - cast @samuellhuber or any Maintainer on Farcaster for now

## Overview

## Providers

## Contributing

If you offer data APIs that you'd wish to be included please refer to [Contributing - Adding Providers](#adding-providers)

### Feedback & Ideas (non devs welcome!)

### Code

### Adding Providers

Have a look at `src/providers/thirdpartyProvider.ts` which is a template for adding new Providers.

Then register your Provider class with a `nameProvider.ts` file in `src/providers/thirdparty/` with creation of your class.

your file needs to export a Provider that extens the ThirdPartyProvider like the following code sample

```typescript
export class NameProvider extends ThirdParty {
// add constructor to init your values
// like an API key etc ...
}
```
3 changes: 0 additions & 3 deletions apps/api/.env.example

This file was deleted.

4 changes: 0 additions & 4 deletions apps/api/.eslintrc.js

This file was deleted.

37 changes: 0 additions & 37 deletions apps/api/.gitignore

This file was deleted.

8 changes: 0 additions & 8 deletions apps/api/README.md

This file was deleted.

Loading
Loading