BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
d59aed94
Commit
d59aed94
authored
Aug 10, 2017
by
Eric Eastwood
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move syntax highlighting into a method
Fix
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/12198#note_37142936
parent
3a9f210b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
repo_preview.vue
app/assets/javascripts/repo/components/repo_preview.vue
+8
-2
No files found.
app/assets/javascripts/repo/components/repo_preview.vue
View file @
d59aed94
...
...
@@ -4,7 +4,7 @@ import Store from '../stores/repo_store';
export
default
{
data
:
()
=>
Store
,
mounted
()
{
$
(
this
.
$el
).
find
(
'.file-content'
).
syntaxHighlight
();
this
.
highlightFile
();
},
computed
:
{
html
()
{
...
...
@@ -12,10 +12,16 @@ export default {
},
},
methods
:
{
highlightFile
()
{
$
(
this
.
$el
).
find
(
'.file-content'
).
syntaxHighlight
();
},
},
watch
:
{
html
()
{
this
.
$nextTick
(()
=>
{
$
(
this
.
$el
).
find
(
'.file-content'
).
syntaxHighlight
();
this
.
highlightFile
();
});
},
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment