https://github.com/hugo-fixit/cmpt-mdevtools
Mobile devtools component powered by vConsole and eruda.
https://github.com/hugo-fixit/cmpt-mdevtools
eruda hugo theme-component vconsole
Last synced: about 1 month ago
JSON representation
Mobile devtools component powered by vConsole and eruda.
- Host: GitHub
- URL: https://github.com/hugo-fixit/cmpt-mdevtools
- Owner: hugo-fixit
- License: mit
- Created: 2024-08-07T05:49:13.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-09-01T07:07:59.000Z (9 months ago)
- Last Synced: 2025-02-11T10:26:15.411Z (3 months ago)
- Topics: eruda, hugo, theme-component, vconsole
- Language: HTML
- Size: 202 KB
- Stars: 2
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# cmpt-mdevtools
Mobile devtools component powered by vConsole and eruda.
## Requirements
- [FixIt](https://github.com/hugo-fixit/FixIt) v0.3.9 or later.
- [eruda](https://github.com/liriliri/eruda)
- [vConsole](https://github.com/Tencent/vConsole)## Install Component
The installation method is the same as [installing a theme](https://fixit.lruihao.cn/documentation/installation/). There are several ways to install, choose one, for example, install through Hugo Modules:
```diff
[module]
[[module.imports]]
path = "github.com/hugo-fixit/FixIt"
+ [[module.imports]]
+ path = "github.com/hugo-fixit/cmpt-mdevtools"
```## Configuration
```toml
# Mobile Devtools config
[params.mDevtools]
enable = false
# "eruda", "vConsole" supported
type = "eruda"
```## Inject Partial
Inject the `cmpt-mdevtools.html` into the `custom-assets` through the custom block opened by the FixIt theme in the `layouts/partials/custom.html` file:
```go-html-template
{{- define "custom-assets" -}}
{{- partial "inject/cmpt-mdevtools.html" . -}}
{{- end -}}
```## References
- [Develop Theme Components | FixIt](https://fixit.lruihao.cn/contributing/components/)
- [How to Develop a Hugo Theme Component | FixIt](https://fixit.lruihao.cn/components/dev-component/)