A simple package which lets you conveniently consume SCORM 1.2/20004 APIs in your dart/flutter web app. Also handles finding of the SCORM 'API' object in the current or opener
's view hierarchy.
This opens a new scope for Dart/Flutter Web: Beautiful, interactive course content creation
Refer here
import package:scorm/scorm.dart;
- Before doing anything, you need to first find the SCORM API using ScormAPI.findApi, returns status whether SCORM API was found.
- If the API is not found, other methods will return false/null
- Use other methods like
initialize
,setValue
,getValue
,commit
,finish
, etc. according to your needs. - BONUS: Utility methods for SCORM
The example app is deployed at https://scorm-dart.web.app
A complete example to run a Flutter web app as a SCORM package can be found in the example folder
To test it in LMS platforms, just build release version of the example app and create a zip file of the example/build/web folder.
See example/web/imsmanifest.xml for the resources declaration.
- The flutter app can be run in an
iframe
with the example/web/flutter-app.html assrc
- example/web/flutter-app.js creates a custom HTMLElement for testing, which is used in example/web/index.html
- example/web/index.html contains simplify-scorm for emulation of the SCORM API
Create SCORM Package from scratch
Copyright 2021 Shripal Jain
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.