Category "import"

importScripts while error thrown from one of the script

In my chrome extension (manifest V3) I want to import some scripts like jquery and more. Inside my backgound.js I have: try { importScripts('/js/jquery-3.4.

How to import gym retro?

Am a beginner in Python but have some prog exp. Trying to do this tutorial, I even asked the creator for help via Patreon but not gotten much. https://www.youtu

ImportError: cannot import name 'safe_str_cmp' from 'werkzeug.security'

Any ideas on why I get this error? My project was working fine. I copied it to an external drive and onto my laptop to work on the road; it worked fine. I copie

LARK: Parsing : Implementing import file?

How would you implement a grammar that can import a file and still parsing it using LARK ? f.e.: @import file.txt .....

Error while importing VGG16 h5 file ValueError: No model found in config file

I tried to import vgg16 which I downloaded from google storage import keras import cv2 from keras.models import Sequential, load_model But I got th

How to reimport module with ES6 import

I need to reimport module integration-test/integration upon every run as this module can have code dynamically changed in it at run time. I am using NodeJS with

IMPORTHTML on Google Sheets returning a #N/A error, but only in one document

I have a Google Sheets document where I track the prices of several stocks. I made this a couple of months ago, and have been experiencing this issue for the pa

import a function from another .ipynb file

I defined a hello world function in a file called 'functions.ipynb'. Now, I would like to import functions in another file by using "import functions". I am sur

How do I import svg from file to a component in angular 5?

All tutorials with adding svg to a component in AngularCli that I found recommend to insert it in html template, something like this: <div> <svg vi

Use imports with string that comes from localStorage

I need to show/hide different menu based on rights that are send from database and saved in localStorage. Here is the imported menus import tripOrders from './t

es6 import for side effects meaning

I was reading the es6 import statement reference on MDN. The syntax: import "my-module"; will import an entire module for side effects only, without importin

Faust doesn't like relative path

I'm trying to clean up my code and have moved the models.py file to the top level, as other modules other than the faust ones will use this now. The folder stru

How to use peerjs (import and require both fail)

I want to use peerjs in a script (that I use in a html file). When I try import Peer from "peerjs", I get an error saying "Cannot use import statement outside a

Named export and default export in the same file

I am trying to put default and named export in same file. Example: // file name : utils/fetch export default fetchUtil; module.exports = { fetch : fetchUt

ReferenceError: can't access lexical declaration `Tag' before initialization

Hi I'm working on a Vanilla JS SPA project, and I wanted to implement some principles from React, but just in plain JavaScript. But there is an issue with impo

Import a function from a module in another folder in parent directory

I have been trying unsuccessfully to solve this for hours now. This is my folder structure. /parent_folder main.py module1/ script1.py

Typedoc / Typescript Compiler throws error on an imported type

Summary I am attempting to build documentation for a TypeScript project using Typedoc. Unfortunately, Typedoc is yielding errors on an import statement I use in

How to programmatically add root folder to the path for every script?

The file structure I currently have is something like: __init__.py script_folder __init__.py s1.py s2.py b_folder __init__.py b1.py b2.p

Svelte/SvelteKit: Dynamic import of components with variable

I want to dynamically import components without importing a specific component. I want to set the component name with a variable, received from the store: <s

Example of " remove unused imports" can have bad side effects in python?

I'm looking for an example of how removing unused imports can lead to breaking otherwise valid programs. My question was inspired looking at this issue: https: