vitelabs / vite.js Goto Github PK
View Code? Open in Web Editor NEWVite JavaScript SDK
Home Page: https://docs.vite.org/vite.js/
Vite JavaScript SDK
Home Page: https://docs.vite.org/vite.js/
Error message: params should be hex-string
Hi,
I'm getting into vite.js and noticing that most of the imports are broken in the @Vite\vitejs\dist\es5\ folder
for example:
Cannot find module 'utils/tools'
at Object.<anonymous> (C:\dev\vite-server\node_modules\@vite\vitejs\dist\es5\utils\encoder.js:4:15)
the import is:
var tools_1 = require("utils/tools");
However what would work for me is:
var tools_1 = require("./tools");
Does it have anything to do with my configuration?
I am using node v10.15.1
Thanks
Hi,
I'm implementing transaction auto-receive.
My account has quota (15 UT).
If use transaction.send(), or transaction.autoSend, it throws the error "out of quota".
But transaction.sendByPoW(), it works
here is my working code, please tell me how I could use quota instead of PoW
async receiveAccountBlock(): Promise<void> {
const transaction = new Transaction(this.address)
.receive({ sendBlockHash: this.hash })
transaction.setProvider(this.client)
transaction.setHeight(`${this.previousAccountHeight + 1}`)
transaction.setPreviousHash(this.previousHash)
transaction.sign(PRIVATE_KEY)
await transaction.sendByPoW(PRIVATE_KEY)
}
Got the following security warning while importing vitejs package
$ npm audit
=== npm audit security report ===
Manual Review
Some vulnerabilities require your attention to resolve
Visit https://go.npm.me/audit-guide for additional guidance
High Regular Expression Denial of Service
Package trim-newlines
Patched in >=3.0.1 <4.0.0 || >=4.0.1
Dependency of @vite/vitejs
Path @vite/vitejs > conventional-changelog-cli >
conventional-changelog > conventional-changelog-core >
get-pkg-repo > meow > trim-newlines
More info https://npmjs.com/advisories/1753
found 1 high severity vulnerability in 339 scanned packages
1 vulnerability requires manual review. See the full report for details.
Hi!
Where I can find a list of public RPC endpoints? Perhaps I was looking badly, but in the documentation I could not find the relevant information.
Emitting the event in the contract:
event TestEvent(bool success, string successStr);
bool success = true;
emit TestEvent(success, success ? "true" : "false");
success = false;
emit TestEvent(success, success ? "true" : "false");
Decoding the event with vite-js (abi.decodeLog):
{"success": "1", "successStr":"true"}
{"success": "1", "successStr":"false"}
Expected:
Versions used:
When I try to use the lib in a linux environment, I got the following error:
node_modules/@vite/vitejs/distSrc/index.ts:6:32 - error TS2307: Cannot find module './accountblock/index' or its corresponding type declarations.
import * as _accountBlock from './accountblock/index';
node_modules/@vite/vitejs/distSrc/viteAPI/index.ts:5:118 - error TS2307: Cannot find module './../accountblock/utils' or its corresponding type declarations.
import { Default_Contract_TransactionType, encodeContractList, getTransactionType, decodeContractAccountBlock } from './../accountblock/utils';
But in Windows everything works fine. I'm using the latest version
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.