Skip to content

Conversation

@letorbi
Copy link

@letorbi letorbi commented May 8, 2023

This PR allows to load the code as an ES6 module, by adding the main function TouchMenuLA explicitly to the window object. This should not change any behavior and cause no unwanted side-effects.

Apart from that the main value in package.json has been set to the minimized script to avoid the need to specify the full path to the JS file.

Once the PR is merged, the the JS code for the touch menu can be loaded as follows:

import { } from "hammerjs";
import { } from "touch-menu-la";

The CSS still needs to be loaded as before.

I've just ported an app for hangboard training from Cordova to Capacitor, which required this little change to make it work again, and thought that it might be helpful for others as well...

@letorbi
Copy link
Author

letorbi commented Feb 27, 2025

@ericktatsui Hi, again :) Is there any change that this PR will be merged? The changes helped me when reviving two old projects already, so it would be great, if you would consider merging them even though Touch-Menu-Like-Android is not in active development anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant