fkling / fkling/astexplorer

[feature request] Adding @babel/template

Open
#492 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
6.5k
Forks
772
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
`babel-template` used to be available on `t` as in:

```
export default function(babel) {
const { types: t } = babel; // t.template was here!
```

But now `@babel/template` is it its own module.

Is there any way for us to be able to import `@babel/template`? It is a really handy feature when rewriting large blocks of code.

**Expected behavior**
Be able to import `@babel/template`

**astexplorer settings:**
- Selected parser: babylon7
- Selected transformer (if applicable): babel7
- Contents of the local storage key `explorerSettingsV1` (code can be removed if you don't want it to be public)

**Additional context**
Much easier to debug making a new template in AST explorer versus a node script!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.