Skip to content
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
11 changes: 6 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ jobs:
ci:
name: CI
runs-on: ubuntu-latest
strategy:
matrix:
command: ["ci:lint", "ci:test", "build"]

steps:
- name: Checkout Repo
uses: actions/checkout@v4
Expand All @@ -26,8 +30,5 @@ jobs:
- name: Install Dependencies
run: pnpm install

- name: Test
run: pnpm test

- name: Prepack
run: pnpm prepack
- name: Run Command
run: pnpm ${{ matrix.command }}
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,6 @@ jobs:
--generate-notes

- name: Publish to npm
run: pnpm publish --no-git-checks
run: pnpm -F @offlegacy/event-tracker publish --no-git-checks
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ node_modules
out/
build
dist

.turbo

# Misc
.DS_Store
Expand Down
2 changes: 1 addition & 1 deletion .husky/pre-push
Original file line number Diff line number Diff line change
@@ -1 +1 @@
pnpm lint-staged && pnpm test
pnpm lint-staged && pnpm ci:test
2 changes: 1 addition & 1 deletion .lintstagedrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"*.{ts,tsx}": ["pnpm lint --fix", "prettier --write --ignore-unknown"]
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
8 changes: 4 additions & 4 deletions docs/package.json → docs/offlegacy.org/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "docs",
"name": "@offlegacy/offlegacy.org",
"version": "0.1.0",
"private": true,
"type": "module",
Expand All @@ -8,11 +8,12 @@
"build": "next build",
"start": "next start",
"lint": "next lint",
"postbuild": "pagefind --site .next/server/app --output-path public/_pagefind"
"postbuild": "pagefind --site .next/server/app --output-path public/_pagefind",
"clean": "rimraf ./next ./node_modules"
},
"dependencies": {
"@amplitude/analytics-browser": "^2.11.11",
"@offlegacy/event-tracker": "latest",
"@offlegacy/event-tracker": "workspace:*",
"@uidotdev/usehooks": "^2.4.1",
"codehike": "^1.0.7",
"lucide-react": "^0.525.0",
Expand All @@ -29,7 +30,6 @@
"@types/node": "^20",
"@types/react": "^19.1.9",
"@types/react-dom": "^19.1.7",
"eslint": "^9",
"eslint-config-next": "15.3.5",
"pagefind": "^1.3.0",
"postcss": "^8",
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import rootConfig from "../prettier.config.js";
import rootConfig from "../../prettier.config.js";

/** @type {import("prettier").Config} */
const config = {
Expand Down
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
75 changes: 13 additions & 62 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,6 @@
{
"name": "@offlegacy/event-tracker",
"version": "1.2.1",
"description": "The best solution for event tracking in React applications.",
"keywords": [
"react",
"analytics",
"google-analytics",
"amplitude",
"logger",
"event tracking",
"tracker",
"tracking"
],
"name": "event-tracker",
"private": true,
"homepage": "https://event-tracker.offlegacy.org",
"bugs": "https://github.com/offlegacy/event-tracker/issues",
"repository": {
Expand All @@ -20,50 +9,24 @@
},
"license": "MIT",
"author": "@stakbucks <Hwang Taehwan>",
"exports": {
".": {
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
},
"require": {
"types": "./dist/index.d.cts",
"default": "./dist/index.cjs"
}
},
"./package.json": "./package.json"
},
"sideEffects": false,
"packageManager": "pnpm@9.14.2",
"type": "module",
"scripts": {
"dev": "tsup --watch",
"build": "tsup",
"build:docs": "cd docs && pnpm build",
"dev:docs": "cd docs && pnpm dev",
"test": "vitest --run",
"test:watch": "vitest",
"lint": "eslint --cache --ignore-pattern=docs/** .",
"prepack": "pnpm build",
"dev": "turbo run dev",
"build": "turbo run build",
"ci:test": "turbo run ci:test",
"ci:lint": "turbo run ci:lint",
"prepare": "husky",
"release": "pnpm build && npm publish",
"format": "prettier --write --ignore-pattern \"docs/**\" .",
"format:check": "prettier --check --ignore-pattern \"docs/**\" .",
"format:file": "prettier --write"
"format": "prettier --write \"**/*.{ts,tsx,md}\"",
"clean": "turbo run clean"
},
"main": "dist/index.cjs",
"module": "dist/index.js",
"types": "dist/index.d.ts",
"files": [
"dist"
],
"devDependencies": {
"@cspell/eslint-plugin": "^8.17.1",
"@eslint-react/eslint-plugin": "^1.22.1",
"@testing-library/jest-dom": "^6.6.3",
"@testing-library/react": "^16.1.0",
"@testing-library/user-event": "^14.5.2",
"@types/eslint": "^9.6.1",
"@types/react": "^19.0.2",
"@typescript-eslint/eslint-plugin": "^8.18.2",
"@typescript-eslint/parser": "^8.18.2",
"eslint": "^9.17.0",
Expand All @@ -74,23 +37,11 @@
"jsdom": "^25.0.1",
"lint-staged": "^15.3.0",
"prettier": "^3.4.2",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"tsup": "^8.3.5",
"rimraf": "^6.0.1",
"tsdown": "^0.13.1",
"turbo": "^2.5.5",
"typescript": "^5.7.2",
"typescript-eslint": "^8.18.2",
"vitest": "^2.1.8"
},
"peerDependencies": {
"react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
"react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
"zod": "^3.20.0"
},
"publishConfig": {
"access": "public"
},
"dependencies": {
"zod": "^3.20.0"
},
"packageManager": "pnpm@9.14.2"
}
}
File renamed without changes.
21 changes: 21 additions & 0 deletions packages/event-tracker/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2025 OffLegacy

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
64 changes: 64 additions & 0 deletions packages/event-tracker/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
{
"name": "@offlegacy/event-tracker",
"version": "1.2.1",
"description": "The best solution for event tracking in React applications.",
"keywords": [
"react",
"analytics",
"google-analytics",
"amplitude",
"logger",
"event tracking",
"tracker",
"tracking"
],
"homepage": "https://event-tracker.offlegacy.org",
"bugs": "https://github.com/offlegacy/event-tracker/issues",
"repository": {
"type": "git",
"url": "git+https://github.com/offlegacy/event-tracker.git"
},
"license": "MIT",
"author": "@stakbucks <Hwang Taehwan>",
"exports": {
".": {
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
},
"require": {
"types": "./dist/index.d.cts",
"default": "./dist/index.cjs"
}
},
"./package.json": "./package.json"
},
"sideEffects": false,
"type": "module",
"scripts": {
"dev": "tsdown --watch",
"build": "tsdown",
"ci:test": "vitest --run",
"ci:test:watch": "vitest",
"ci:lint": "eslint --cache .",
"clean": "rimraf ./dist ./coverage ./node_modules",
"publish": "npm publish"
},
"main": "dist/index.cjs",
"module": "dist/index.js",
"types": "dist/index.d.ts",
"files": [
"dist"
],
"devDependencies": {
"@types/react": "^19.0.2",
"react": "^19.1.1"
},
"peerDependencies": {
"react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
"zod": "^3 || ^4"
},
"publishConfig": {
"access": "public"
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 2 additions & 4 deletions tsup.config.ts → packages/event-tracker/tsdown.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { defineConfig } from "tsup";
import { defineConfig } from "tsdown";

export default defineConfig({
banner: { js: '"use client"' },
Expand All @@ -8,8 +8,6 @@ export default defineConfig({
outDir: "dist",
sourcemap: true,
dts: true,
splitting: true,
bundle: true,
clean: true,
external: ["react", "react-dom"],
external: ["react", "zod"],
});
File renamed without changes.
Loading