UNPKG

@mathrunet/masamune

Version:

Manages packages for the server portion (NodeJS) of the Masamune framework.

70 lines (52 loc) 2.84 kB
<p align="center"> <a href="https://mathru.net"> <img width="240px" src="https://raw.githubusercontent.com/mathrunet/node_masamune/main/.github/images/icon.png" alt="Masamune logo" style="border-radius: 32px"s><br/> </a> <h1 align="center">Masamune Framework</h1> </p> <p align="center"> <a href="https://github.com/mathrunet"> <img src="https://img.shields.io/static/v1?label=GitHub&message=Follow&logo=GitHub&color=333333&link=https://github.com/mathrunet" alt="Follow on GitHub" /> </a> <a href="https://x.com/mathru"> <img src="https://img.shields.io/static/v1?label=@mathru&message=Follow&logo=X&color=0F1419&link=https://x.com/mathru" alt="Follow on X" /> </a> <a href="https://www.youtube.com/c/mathrunetchannel"> <img src="https://img.shields.io/static/v1?label=YouTube&message=Follow&logo=YouTube&color=FF0000&link=https://www.youtube.com/c/mathrunetchannel" alt="Follow on YouTube" /> </a> <a href="https://github.com/invertase/melos"> <img src="https://img.shields.io/static/v1?label=maintained%20with&message=melos&color=FF1493&link=https://github.com/invertase/melos" alt="Maintained with Melos" /> </a> </p> <p align="center"> <a href="https://github.com/sponsors/mathrunet"><img src="https://img.shields.io/static/v1?label=Sponsor&message=%E2%9D%A4&logo=GitHub&color=ff69b4&link=https://github.com/sponsors/mathrunet" alt="GitHub Sponsor" /></a> </p> --- [[GitHub]](https://github.com/mathrunet) | [[YouTube]](https://www.youtube.com/c/mathrunetchannel) | [[Packages]](https://pub.dev/publishers/mathru.net/packages) | [[X]](https://x.com/mathru) | [[LinkedIn]](https://www.linkedin.com/in/mathrunet/) | [[mathru.net]](https://mathru.net) --- Just load the package in index.ts and pass the predefined data to the methods to implement the server side. Also, [katana_functions_firebase](https://pub.dev/packages/katana_functions_firebase/score) can be used to execute server-side functions from methods defined on the client side, allowing for safe implementation. # Installation Install the following packages ```bash npm install @mathrunet/masamune ``` # Implementation Import the package as follows and pass the value of `exports` and the list of functions you wish to define to the `deploy` function. ```dart import * as m from "@mathrunet/masamune"; // Define [m.Functions.xxxx] for the functions to be added to Functions. // // Functionsに追加する機能を[m.Functions.xxxx]を定義してください。 m.deploy( exports, [ // Function for PUSH Notification. m.Functions.send_notification, ], ); ``` Functions passed to deploy are deployed to Cloud Functions for Firebase. # GitHub Sponsors Sponsors are always welcome. Thank you for your support! [https://github.com/sponsors/mathrunet](https://github.com/sponsors/mathrunet)