title: How to add LinkedIn Badge DOM Changed Code when the component is refreshed
body: <p>I have embedded LinkedIn Badge html code in angular html file and added </p>
  
  <pre><code>&lt;script type="text/javascript" 
    src="https://platform.linkedin.com/badges/js/profile.js" async defer&gt;
  &lt;/script&gt; 
  </code></pre>
  
  <p>in index.html, still it is showing only link not the badge. The badge only shows up when I refresh the page and inside the DOM the code gets added when the component is refreshed.</p>
  
  <p>I want to add this DOM code so the badge gets displayed without the refreshing the page. How this can be done?</p>
  
  <p>Following is my html code</p>
  
  <pre><code>&lt;div class="LI-profile-badge"  data-version="v1" data-size="medium" 
      data-locale="en_US" data-type="horizontal" data-theme="light" 
      data-vanity="divya-dave-23456b356"&gt;
    &lt;a class="LI-simple-link" 
        href='https://in.linkedin.com/in/divya-trk=profile-badge'&gt;
      Divya
    &lt;/a&gt;
  &lt;/div&gt; 
  </code></pre>
  
  <p>Following the code which gets added on DOM when the page is refreshed:</p>
  
  <pre><code>&lt;div&gt;&lt;script src="https://static-exp1.licdn.com/sc/h/3qk7aqkysw7gz575y2ma1e5ky" type="text/javascript"&gt;&lt;/script&gt;&lt;code id="__pageContext__" style="display: none;"&gt;&lt;!----&gt;&lt;/code&gt;&lt;script src="https://static-exp1.licdn.com/sc/p/com.linkedin.badger-frontend%3Abadger-frontend-static-content%2B1.0.2/f/%2Fbadger-frontend%2Fsc-hashes%2Fsc-hashes_en_US.js"&gt;&lt;/script&gt;&lt;script src="https://static-exp1.licdn.com/sc/h/19dd5wwuyhbk7uttxpuelttdg"&gt;&lt;/script&gt;&lt;link rel="stylesheet" href="https://static-exp1.licdn.com/sc/h/c5izpj9x1e2q31kvb2g3w9ptv"&gt;&lt;div dir="ltr" class="LI-badge-container-horizontal-light LI-badge-container horizontal light medium" style="display: none"&gt; &lt;div class="LI-profile-badge-header LI-name-container LI-row"&gt;&lt;div class="LI-col"&gt;&lt;div class="LI-profile-pic-container"&gt;&lt;img src="https://media-exp1.licdn.com/dms/image/C5103AQFYXRtyDCvPsA/profile-displayphoto-shrink_200_200/0?e=1591833600&amp;amp;v=beta&amp;amp;t=F-mTttfMKDxEk-8-6hkrPZCRnbibURICKa-U-m-gu60" class="LI-profile-pic"&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="LI-col LI-header"&gt;&lt;div class="LI-name"&gt;&lt;a href="https://in.linkedin.com/in/divya-dave?trk=profile-badge-name"&gt;Divya Dave&lt;/a&gt;&lt;/div&gt;&lt;div class="LI-title"&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;ul class="LI-more-info"&gt;&lt;li class="LI-field"&gt;&lt;img src="https://static-exp1.licdn.com/scds/common/u/images/themes/katy/ghosts/company/ghost_company_80x80_v1.png" class="LI-field-icon" alt=""&gt;&lt;/li&gt;&lt;li class="LI-field"&gt;&lt;img src="https://media-exp1.licdn.com/dms/image/C4E0BAQF-NKQHUG7hUg/company-logo_200_200/0?e=1594252800&amp;amp;v=beta&amp;amp;t=PCVRH-tcYArMwDqJ27wRVcRwRtcVwvAkhOYU5Ml-GKQ" class="LI-field-icon"&gt;&lt;a href=""&gt;&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="LI-footer LI-row"&gt;&lt;a href="" class="LI-view-profile"&gt;View profile&lt;/a&gt;&lt;span class="LI-logo"&gt;&lt;img src="https://static-exp1.licdn.com/scds/common/u/images/logos/linkedin/logo_linkedin_93x21_v2.png" alt="LinkedIn" class="LI-icon"&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;
  </code></pre>
  
  <p>I want to show badge without refreshing the component</p>