by nonrandomstring · 4y ago · 0 comments
Now that I think about it, I really should set up a "snippet" to type this for me:
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd import qualified Foo.Bar as Baz import anyNamespace from 'module.js'
import { subModule } from 'module.js'
import { subModule as anyName } from 'module.js'A) I type "import {} from 'module" first and then go back and add modules
or more often these days,
B) I let Copilot guess for me, which combined with my predictable file organization usually results in the right autocomplete.
Option A can be improved upon by writing a macro/template with slots in the correct order.
(import (prefix (rename #;from (rnrs r5rs)
(delay #;as eval-later)
(force #;as eval-now))
r5rs:))
And from (rnrs r5rs) it will import delay as r5rs:eval-later and force as r5rs:eval-now.