Cordova Android Fingerprint Auth 插件使用教程

Cordova Android Fingerprint Auth 插件使用教程

cordova-plugin-android-fingerprint-authA cordova plugin for fingerprint authentication using the hardware fingerprint scanner on devices running Android 6+项目地址:https://gitcode.com/gh_mirrors/co/cordova-plugin-android-fingerprint-auth

1. 项目的目录结构及介绍




cordova-plugin-android-fingerprint-auth/


├── res/


│   └── android/


│       └── ...


├── src/


│   └── android/


│       └── ...


├── www/


│   └── ...


├── .gitignore


├── LICENSE


├── README.md


├── changelog.md


├── index.d.ts


├── package.json


└── plugin.xml

res/android/: 包含Android资源文件。src/android/: 包含Android源代码文件。www/: 包含插件的Web接口文件。.gitignore: Git忽略文件配置。LICENSE: 项目许可证文件。README.md: 项目说明文档。changelog.md: 项目更新日志。index.d.ts: TypeScript定义文件。package.json: Node.js包配置文件。plugin.xml: Cordova插件配置文件。

2. 项目的启动文件介绍

项目的启动文件主要是plugin.xml,它是Cordova插件的配置文件,定义了插件的名称、版本、依赖关系以及如何集成到Cordova项目中。




<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0"


        id="cordova-plugin-android-fingerprint-auth"


        version="1.4.0">


    <name>FingerprintAuth</name>


    <js-module name="FingerprintAuth" src="www/FingerprintAuth.js">


        <clobbers target="FingerprintAuth" />


    </js-module>


    <platform name="android">


        <config-file target="res/xml/config.xml" parent="/*">


            <feature name="FingerprintAuth">


                <param name="android-package" value="com.mjwheatley.cordova.plugin.android.fingerprintauth.FingerprintAuth"/>


            </feature>


        </config-file>


        <source-file src="src/android/FingerprintAuth.java" target-dir="src/com/mjwheatley/cordova/plugin/android/fingerprintauth"/>


    </platform>


</plugin>

3. 项目的配置文件介绍

package.json: 定义了插件的元数据,包括名称、版本、依赖等。




{


  "name": "cordova-plugin-android-fingerprint-auth",


  "version": "1.4.0",


  "description": "A cordova plugin for fingerprint authentication using the hardware fingerprint scanner on devices running Android 6+",


  "cordova": {


    "id": "cordova-plugin-android-fingerprint-auth",


    "platforms": [


      "android"


    ]


  },


  "repository": {


    "type": "git",


    "url": "git+https://github.com/mjwheatley/cordova-plugin-android-fingerprint-auth.git"


  },


  "keywords": [


    "ecosystem:cordova",


    "cordova-android",


    "fingerprint",


    "authentication"


  ],


  "author": "mjwheatley",


  "license": "Apache-2.0",


  "bugs": {


    "url": "https://github.com/mjwheatley/cordova-plugin-android-fingerprint-auth/issues"


  },


  "homepage": "https://github.com/mjwheatley/cordova-plugin-android-fingerprint-auth#readme"


}

plugin.xml: 如上所述,定义了插件的集成方式和文件路径。

通过以上介绍,您可以更好地理解和使用cordova-plugin-android-fingerprint-auth插件。

cordova-plugin-android-fingerprint-authA cordova plugin for fingerprint authentication using the hardware fingerprint scanner on devices running Android 6+项目地址:https://gitcode.com/gh_mirrors/co/cordova-plugin-android-fingerprint-auth

© 版权声明

相关文章

暂无评论

您必须登录才能参与评论!
立即登录
暂无评论...