Add the following code at the end of the .zshrc
configuration file.
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
nvm use
JavaScript code runs single threaded. There is just one thing happening at a time.
This is good because devs dont need to worry about concurrency issues, the only caveat is to know how not to block that single thread like synchronous network calls or infinite loops.
In most browser there is an event loop for every browser tab, in other words, the environment manages multiple concurrent event loops, to handle API calls for example, Web Workers run in their own event loop as well.
You mainly need to be concerned that your code will run on a single event loop, and write code with this thing in mind to avoid blocking it.
export interface DataAttributes { | |
// eslint-disable-next-line @typescript-eslint/no-explicit-any | |
[n: `data-${string}`]: any | |
} | |
// more info about it: | |
// https://github.com/microsoft/TypeScript/issues/47211 | |
// https://github.com/microsoft/TypeScript/issues/28960 |
import { QueryClient, QueryClientProvider } from '@tanstack/react-query' | |
import { render as rtlRender } from '@testing-library/react' | |
// eslint-disable-next-line @typescript-eslint/no-explicit-any | |
function render(ui: React.ReactElement, { ...renderOptions } = {} as any) { | |
const queryClient = new QueryClient() | |
const Wrapper = ({ children }: { children: React.ReactNode }) => ( | |
<QueryClientProvider client={queryClient}>{children}</QueryClientProvider> | |
) |
Run this command
yarn create vite <my-awesome-project> --template vue-ts
This will create a VueJS project with TypeScript support, but it doesn't add the configuration for Prettier or Eslint, let's add that.
keep-open=yes | |
reset-on-next-file=pause | |
geometry=50%x50% | |
pause |
Information From: https://developers.google.com/protocol-buffers/docs/proto3
Declaring Message In Protocol Buffer:
As you can see, each field in the message definition has a unique number.
Field numbers identify fields in message binary format. Should not be changed once message is in use