Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First empty line in code fragment silents rules about first empty line in code #78

Closed
vsemozhetbyt opened this issue Jul 5, 2017 · 2 comments

Comments

@vsemozhetbyt
Copy link

From .eslintrc.js:

  'lines-around-directive': ['error', 'never'],

In .js file:

<empty line>
'use strict';
console.log(1);

Message:

  2:1  error  Unexpected newline before "use strict" directive  lines-around-directive

In .md file:

### Heading

```js

'use strict';
console.log(1);
```

No error messages.

@vsemozhetbyt vsemozhetbyt changed the title First empty line in code fragment silent rules about first empty line in code First empty line in code fragment silents rules about first empty line in code Jul 7, 2017
@nzakas
Copy link
Member

nzakas commented Jan 26, 2021

@btmills what do you want to do with this issue?

@btmills
Copy link
Member

btmills commented Feb 27, 2021

remark-parse v7 includes remarkjs/remark#423, which should fix this issue.

btmills added a commit that referenced this issue Feb 27, 2021
`[email protected]` includes
remarkjs/remark#423, which fixes handling of
leading and trailing newlines in fenced code blocks.

Tagging this as `Update` so it'll be semver-minor. Are we comfortable
with a parser major version bump in a semver-minor release?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

4 participants