January 2020
Intermediate to advanced
530 pages
11h 11m
English
The FolderBlock component is rendered after we write the file hashes, the MTH, and the FTH to the blockchain. It lists the files in the directory that are written to the blockchain and the directory path for each file:
{ props.files.map((file,index) => { var splitString = file.split("/"); var reverseArray = splitString.reverse(); return ( <div className="panel-block is-multiline"> <div className="column"> <div key={index} className="columns token"> <div className="column"> <strong>FileName </strong> : {reverseArray[0]} </div> <div className="column"> <strong> Path</strong> : {file} </div> </div> </div> </div> ) }) }
Since the file array contains just the directory location of each file, we iterate ...
Read now
Unlock full access