enter image description here
I put the parcel, but as if the installed dateFns module still does not see
The operability of parcel and dateFns
index.html modules
<script src="./scripts/create-elements.mjs" type="module"></script> <script src="./scripts/storage.mjs" type="module"></script> <script src="./scripts/utils.mjs" type="module"></script> <script src="./scripts/errors-handling.mjs" type="module"></script> <script src="./scripts/favorites.mjs" type="module"></script> <script src="./scripts/ui.mjs" type="module"></script> <script src="./scripts/requests.mjs" type="module"></script> <script src="./scripts/main.mjs" type="module"></script>
utils.mjs
`import { format } from “date-fns”;
export const getTimeByTimestamp = (timestamp) => {
const time = new Date(timestamp);
const dateFormat = 'HH:mm';
return format(time, dateFormat);
}`
New contributor