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

Support Kotlin Code Highlight #1831

Closed
bamboovir opened this issue Sep 2, 2019 · 7 comments · Fixed by #1874 · May be fixed by adamlaska/osmos-cosmos-sdk#5
Closed

Support Kotlin Code Highlight #1831

bamboovir opened this issue Sep 2, 2019 · 7 comments · Fixed by #1874 · May be fixed by adamlaska/osmos-cosmos-sdk#5
Assignees
Labels
complexity: medium Medium complexity contribution welcome Contributions welcome effort: medium Up to a week priority: medium Medium priority issue type: bug Something isn't working

Comments

@bamboovir
Copy link

Feature request

What problem does this feature solve?

Support Kotlin Code Highlight

What does the proposed API look like?

How should this be implemented in your opinion?

@vuepress/core/lib/client/style/config.styl

$codeLang += kt

@vuepress/markdown/lib/highlight.js +=

if(lang === 'kt') {
lang = 'kotlin'
}

Are you willing to work on this yourself?

@kefranabg
Copy link
Collaborator

Hi @bamboovir ,

As we're using prismjs for code highlighting, we're already supporting Kotlin code highlight. Just use the alias kotlin.

@bamboovir
Copy link
Author

Hi @kefranabg, kotlin code highlighting is not work for Code Snippets,
This means that kotlin code imported from other files cannot be highlighted correctly.
https://vuepress.vuejs.org/guide/markdown.html#import-code-snippets

@kefranabg
Copy link
Collaborator

You mean it's not working only with code snippets imports ?

@kefranabg kefranabg reopened this Sep 6, 2019
@bamboovir
Copy link
Author

Yes, and I have given a fix.

@vuepress/core/lib/client/style/config.styl

$codeLang += kt

@vuepress/markdown/lib/highlight.js +=

if(lang === 'kt') {
lang = 'kotlin'
}

@kefranabg kefranabg added complexity: medium Medium complexity contribution welcome Contributions welcome effort: medium Up to a week priority: medium Medium priority issue type: bug Something isn't working labels Sep 9, 2019
@larionov
Copy link
Contributor

@kefranabg @bamboovir Highlighting Kotlin is working already, you just need to use correct language alias (https://prismjs.com/#basic-usage)


2019-09-14_13-17

@bamboovir
Copy link
Author

@larionov it's not working with code snippets imports :(

@kefranabg
Copy link
Collaborator

kefranabg commented Sep 20, 2019

I confirm that it is not working. Contributions welcome !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
complexity: medium Medium complexity contribution welcome Contributions welcome effort: medium Up to a week priority: medium Medium priority issue type: bug Something isn't working
Projects
None yet
3 participants