Skip to content

How to add scripts using fastn language? #965

Discussion options

You must be logged in to vote

We can add scripts using the common attribute js.

In <some-file>.ftd

;; any component invocation which has common attributes
-- ftd.text: Some text
js: $js



-- string list js:

-- string: //unpkg.com/[email protected]/dist/web3.min.js:type=text/javascript
-- string: sample.js:type=module

-- end: js

Note:

Use //unpkg.com/[email protected]/dist/web3.min.js instead of https://unpkg.com/[email protected]/dist/web3.min.js.
We are working on the new syntax. Checkout #967 to know more

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Arpita-Jaiswal
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant