[英]How to import API/external JS in a JS file?
我正在為Firefox編寫一個Web擴展,並且我想做與此相同的事情: https : //stackoverflow.com/a/32616807/10452863 ,這意味着使用Google API搜索隨機圖像。
如何在.js文件中導入Google API?
如果您想嘗試任何npm軟件包,我建議googleapis 。 您可以將所有Google API與該node.js客戶端庫一起使用。
To import use ``` const { google } = require("googleapis")```
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.