Skip to content

Instantly share code, notes, and snippets.

View kvedantmahajan's full-sized avatar

K. Vedant Mahajan kvedantmahajan

  • Toppr
  • Bangalore
View GitHub Profile
@kvedantmahajan
kvedantmahajan / package.json
Created November 18, 2019 07:33
package.json root final
{
"name": "root",
"private": true,
"workspaces": [
"packages/*"
],
"scripts": {
"lint": "eslint './packages/**/*.{ts,tsx}'",
"lint:fix": "eslint './packages/**/*.{ts,tsx}' --fix",
"build": "yarn workspace ui-components tsc && yarn workspace ui-core tsc"
@kvedantmahajan
kvedantmahajan / .eslintignore
Last active November 18, 2019 14:04
.eslintignore
packages/**/src/**/__tests__/**
packages/**/src/**/__snapshots__/**
packages/**/dist/
node_modules
@kvedantmahajan
kvedantmahajan / .eslintrc
Last active July 12, 2021 13:39
.eslintrc
{
"parser": "@typescript-eslint/parser",
"parserOptions": {
"sourceType": "module",
"project": "./tsconfig.json"
},
"plugins": [
"react",
"prettier",
"@typescript-eslint"
@kvedantmahajan
kvedantmahajan / tsconfig.json
Created November 17, 2019 16:25
tsconfig.json root
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"rootDir": "packages",
@kvedantmahajan
kvedantmahajan / tsconfig.json
Last active November 17, 2019 16:30
tsconfig.json ui-core
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"declaration": true,
@kvedantmahajan
kvedantmahajan / tsconfig.json
Created November 17, 2019 16:17
tsconfig.json ui-components
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"declaration": true,
import React from "react";
const Button = () => {
const handleChange = (e: React.MouseEvent<HTMLButtonElement>) => {
console.log(e);
}
return (
<button onClick={handleChange}>
Sample Button
</button>
@kvedantmahajan
kvedantmahajan / tsconfig.json
Last active November 17, 2019 16:05
tsconfig.json initial
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"rootDir": "packages",
{
"packages": [
"packages/*"
],
"version": "independent",
"npmClient": "yarn",
"useWorkspaces": true
}
@kvedantmahajan
kvedantmahajan / package.json
Last active November 17, 2019 14:16
The monorepo project
{
"name": "root",
"private": true,
"workspaces": [
"packages/*"
],
"devDependencies": {
"lerna": "^3.18.4"
}
}