This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { | |
| useState, | |
| useEffect, | |
| createContext, | |
| useContext} from 'react'; | |
| const defaultValue = {} | |
| const BreakpointContext = createContext(defaultValue); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* https://github.com/mblode/marx/issues/37 */ | |
| /* Marx + Variables POC */ | |
| :root { | |
| --xs-pad: 4px; | |
| --sm-pad: 8px; | |
| --md-pad: 16px; | |
| --lg-pad: 20px; | |
| --xlg-pad: 40px; | |
| --primary: #007bff; | |
| --hover: #0069d9; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| let { isString, isEmpty } = _ | |
| // let isEmpty = obj => Object.keys(obj).length === 0 | |
| let isArray = Array.isArray | |
| function dblQuote(str) { return `"${str}"` } | |
| function buildFieldsStr(fields) { | |
| let fieldsStr = Object.entries(fields).map(([key, val]) => { | |
| console.log(key, val) | |
| console.log(`${val}: ${isEmpty(val)}`) |