coffeescript
coffeescript copied to clipboard
Feature request: Multiple imports
I was thinking about if coffeescript had a way to make multiple imports, like:
import (
"one"
"two"
"three"
"four"
) as (
@one
two
{ three }
);
which could translate to:
import * as one from "one"
import two from "two"
import { three } from "three"
import "four"
You can also:
import (
"one"
"two"
)
which will be:
import "one"
import "two"
now i don't know if this is any better than the normal imports, but it removes the duplicate import statements atleast...
its visually less plesant to look at than the 4 imports tbh. Even though I do agree the pythonic way of imports is more appealing than JS with their:
from module.path import func, cls
import module.path.func as fn
giving you the sense that from that file comes just this small thing.