Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yisibell/mymark
A canvas watermark builder.
https://github.com/yisibell/mymark
canvas watermark
Last synced: about 1 month ago
JSON representation
A canvas watermark builder.
- Host: GitHub
- URL: https://github.com/yisibell/mymark
- Owner: yisibell
- License: mit
- Created: 2022-01-19T03:22:03.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2024-01-03T02:24:45.000Z (11 months ago)
- Last Synced: 2024-10-06T20:34:50.185Z (about 1 month ago)
- Topics: canvas, watermark
- Language: TypeScript
- Homepage:
- Size: 114 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# mymark
A canvas watermark builder(水印生成工具)。
- [Release Notes](./CHANGELOG.md).
# Installation
```bash
# yarn
$ yarn add mymark# npm
$ npm i mymark
```# Usage
```js
// 导入
import { watermark } from 'mymark'
// 调用, options 参数具体见下表
watermark(options)
```## 以 `` 标签的方式引用
```html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>watermark demo</title>
<style>
#app {
height: 95vh;
}
</style>
</head>
<body>
<div id="app">hello watermark!</div>
<script src="./mymark.umd.js">
// MyMark 被暴露到 window
const { watermark } = MyMarkwatermark({ content: 'build by elenh' })