Overview

I created a page where Universal Viewer is displayed across the entire page, as shown below, so this is a memo of the process. Universal Viewer v4 is used.

https://nuxt3-demo-nine.vercel.app/uv/?manifest=https://dl.ndl.go.jp/api/iiif/3437686/manifest.json

Source Code

Please refer to the following source code.

https://github.com/nakamura196/nuxt3-demo/blob/main/public/uv/index.html

Referring to the following page:

https://github.com/UniversalViewer/universalviewer/wiki/UV-Examples

and the following sample, the viewer size is adjusted to change according to page resizing.

https://codesandbox.io/s/uv-url-adapter-example-9d6x8

It also includes code to receive a manifest query parameter.

References

I attempted to integrate it into Nuxt3 without using a CDN, referring to the following, but was unable to get it working. I plan to continue investigating this.

https://codesandbox.io/s/uv-vite-example-9ie3rh

Summary

The following page provides a full-screen display example using v3, but at the time of writing this article, no v4 example was available.

https://universalviewer.io/examples/uv/uv.html#?manifest=https://dl.ndl.go.jp/api/iiif/3437686/manifest.json

I hope this serves as a helpful reference.