question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Displaying raw HTML and non html content in same column

See original GitHub issue

I wanted to display raw HTML with v-html and normal text element in the same row. When using the template slot it does not display the html element, when using the <span> it only display the html.

Is there any workaround for this?

What i wanted to achieve is.

Html and Text

<template>
  <div>
    <b-table :fields="fields" :items="items">
      <span slot="html" slot-scope="data" v-html="data.value"></span>
    </b-table>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        fields: ["html"],
        items: [
          {
            text: 'This is <i>escaped</i> content',
            html: 'This is <i>notice for student</i>',
            created_at: '4/30/2019'
          }
        ]
      }
    }
  }
</script>

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
aakashbashyal21commented, Apr 30, 2019

Worked perfectly, learned complete new thing today. Thank you.

1reaction
tmorehousecommented, Apr 30, 2019
Read more comments on GitHub >

github_iconTop Results From Across the Web

How to display raw HTML code on an HTML page
The tried and true method for HTML: Replace the & character with &; Replace the < character with <; Replace the > character...
Read more >
How do I display HTML tags as Plain Text in columns?
I am using MVC as the backend and I return a JSON result to populate the data table. I want to render the...
Read more >
HTML table basics - Learn web development | MDN
This article gets you started with HTML tables, covering the very basics such as rows, cells, headings, making cells span multiple columns ......
Read more >
Tables in HTML documents
The HTML table model allows authors to arrange data -- text, preformatted text, images, links, forms, form fields, other tables, etc. -- into...
Read more >
&nbsp and HTML Space Challenges and Tricks | Mailtrap Blog
or non-breaking space, is an HTML character used to create a space. ... you'll probably see a raw code displayed on the page....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found