Uncaught type error on netlify cms admin login

194 Views Asked by At

I could not login my netlify cms admin panel, basically it's jekyll theme hosted on Github with custom domain.

When I click on login button it's show a following error on console

enter image description here

My Domain https://www.mominriyadh.me

1

There are 1 best solutions below

0
On

The NetlifyCMS config (config.yml) is using the Netlify git-gateway for authentication. In the page admin/index.html, you need to have the identity widget client script loaded prior to the netlify-cms script.

<!doctype html>
<html>

<head>
  <meta charset="utf-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>Content Manager</title>
  <script src="https://identity-js.netlify.com/v1/netlify-identity-widget.js"></script>
</head>

<body>
  <!-- Include the script that builds the page and powers Netlify CMS -->
  <script src="https://unpkg.com/netlify-cms@^2.0.0/dist/netlify-cms.js"></script>
</body>

</html>

The script is being put in the main default layout only.