Skip to content

Instantly share code, notes, and snippets.

View wagnerpaz's full-sized avatar

Wagner Paz wagnerpaz

View GitHub Profile
@wagnerpaz
wagnerpaz / complexObjectSchema.json
Last active May 22, 2024 15:20
JSON Schema Example
{
"$id": "https://example.com/complex-object.schema.json",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Complex Object",
"type": "object",
"properties": {
"name": {
"type": "string"
},
"age": {
@wagnerpaz
wagnerpaz / App.js
Created March 30, 2020 23:04
How to expose a react component functions using forwardRef and useRefs.
import React, { useRef } from 'react';
import Counter from './components/Counter';
export default () => {
const counterRef = useRef(null);
return (
<fieldset>
<legend>App.js</legend>