For getting tarteaucitron.js lib by composer, the module need a composer.json file like this :
{
"name": "drupal/my_module",
"description": "module_desc",
"type": "drupal-module",
"authors": [
{
"name": "name",
"email": "e_mail"
}
],
"minimum-stability": "dev",
"homepage": "drupal/projet/page",
"support": {
"issues": "drupal/projet/page/issues"
}
"require": {
"amauric/tarteaucitron": "^1.2.0",
},
"repositories": {
"tarteaucitron": {
"type": "package",
"package": {
"name": "AmauriC/tarteaucitron",
"version": "1.2",
"type": "drupal-library",
"dist": {
"url": "https://github.com/AmauriC/tarteaucitron.js/archive/V1.2.zip",
"type": "zip"
},
"require": {
"composer/installers": "^1.2.0"
}
}
}
}
}
Comments
Comment #2
boulaffasae commentedHello DrDam, we appreciate your contribution.
TacJS will move to 3.0 version as soon as possible.
I added the composer.json file to the module, https://git.drupalcode.org/project/tacjs/tree/8.x-3.x.
Comment #4
drdam commentedThe branch 3.x are not available with composer...
Comment #6
boulaffasae commentedHello DrDam, branchs 3.0/3.1 are now available with composer.
but installation still failed, am i missing something ?
Comment #9
boulaffasae commentedtarteaucitron.js is now part of the module TacJS
Comment #11
nonom commentedIt's what we are using in mobile_detect; fit it your needs
Comment #12
nonom commentedDo you want a patch from my side? I'm afraid it means rewrite a few things into the module.
Grats for the module, pretty useful :-)
Comment #13
boulaffasae commentedHi @nonom Thank you very much for the Docs :)
Yes, we really need your and everyone help to make this module more useful.
I think because that
mobiledetect/mobiledetectlibexist at packagist.org, that's why it can be downloaded usingcomposer.json. But i don't know how you could handle the installation path/libraries, /modules, /themes?At the End, we added tarteaucitorn.js JavaScript files to TacJS module, the same way Drupal Core handle third-party libraries such as
Sortable.js