mirror of
https://github.com/phuoc-ng/csslayout.git
synced 2025-10-23 02:36:11 +02:00
Define typescript type for placeholders
This commit is contained in:
@@ -2,7 +2,13 @@ import React from 'react';
|
||||
|
||||
import random from '../helpers/random';
|
||||
|
||||
const Block = ({ justify = 'start', numberOfBlocks = 1, blockHeight = 4 }) => {
|
||||
interface BlockProps {
|
||||
blockHeight?: number;
|
||||
justify?: string;
|
||||
numberOfBlocks?: number;
|
||||
}
|
||||
|
||||
const Block: React.FC<BlockProps> = ({ justify = 'start', numberOfBlocks = 1, blockHeight = 4 }) => {
|
||||
return (
|
||||
<div className={`flex flex-wrap w-100 justify-${justify}`}>
|
||||
{
|
||||
|
Reference in New Issue
Block a user