I want to put a sample xlsx file in my public folder (react project) and others can download this file.
<Button><link rel="chargeSample" href="%PUBLIC_URL%/chargeSample.xlsx"></link></Button>
How can I do this?
The tag defines a link between a document and an external resource. To let download funcionality on your website you should change link tag
import chargeSample from './public/chargeSample.xlsx';
<Button><a href={chargeSample} download="your file name">Download</a></Button>