I have imported solana/web3.js package and it working fine when I am running node js file
import {
Transaction,
SystemProgram,
Keypair,
Connection,
sendAndConfirmTransaction,
clusterApiUrl
} from "@solana/web3.js"
But when I try to connect this file with basic HTML, it throws the error.
Uncaught TypeError: Failed to resolve module specifier "@solana/web3.js". Relative references must start with either "/", "./", or "../".
I also tried with Vue JS project, but it didn't help
You may be trying to use the file without a build system, in which case you should use the unpkg versions, ie:
Documentation at https://www.npmjs.com/package/@solana/web3.js#for-use-in-a-browser-without-a-build-system