bloodymary on Nostr: It’s the difference between commons is and esm. The import statement can be used in ...
It’s the difference between commons is and esm.
The import statement can be used in ESM.
Otherwise you shall use require().
It means you are trying to run the code on the “server” side
Published at
2024-03-23 07:20:57Event JSON
{
"id": "be67fabf9ec5291cf018c169e717b41bdb2cffd649cfd869e4c23b448ca50bc5",
"pubkey": "dd86da06a7ba041622531acb23c4ec2b2dcd51bd9da5b0727de8b79d2a858b50",
"created_at": 1711178457,
"kind": 1,
"tags": [
[
"e",
"e593f2bd7022a78f808398b845b56fb94dcd8c60948357b9d92fcbaf3fbe9033",
"reply"
],
[
"p",
"9cb3545c36940d9a2ef86d50d5c7a8fab90310cc898c4344bcfc4c822ff47bca"
]
],
"content": "It’s the difference between commons is and esm.\nThe import statement can be used in ESM.\n\nOtherwise you shall use require().\n\nIt means you are trying to run the code on the “server” side",
"sig": "56d4766e4b1b8b6fca052ae2ee9c9ab0c0e5769d1db8e2127e1f30aa03d7400596b8414132d976d02158111b02fb6fe2246454eabfd7627a1a423f1d004fadc1"
}