Switch from deprecated Node Sass to Dart Sass compiler using Gulp and change minimum node version to 16.0 and later in the Varbase Email module

Created on 30 March 2022, over 2 years ago
Updated 22 January 2023, over 1 year ago

Problem/Motivation

Following with latest changes from Drupal core package.json file

Warning: LibSass and Node Sass are deprecated. While they will continue to receive maintenance releases indefinitely, there are no plans to add additional features or compatibility with any new CSS or Sass features. Projects that still use it should move onto Dart Sass.
https://www.npmjs.com/package/node-sass

  • The maintainers no longer recommend LibSass for new Sass projects. Use Dart Sass instead.
  • The maintainers recommend all existing LibSass users make plans to eventually move onto Dart Sass, and that all Sass libraries make plans to eventually drop support for LibSass.
  • The maintainers are no longer planning to add any new features to LibSass, including compatibility with new CSS features.
  • LibSass and Node Sass will continue to be maintained indefinitely on a best-effort basis, including fixing major bugs and security issues and maintaining compatibility with the latest Node versions.

Proposed resolution

Change from sass = require("gulp-sass"), to sass = require("gulp-sass")(require('sass')), in the gulpfile.js file
Have the following changes in the package.json file and update the yarn.lock file

    ...
    ...
    "sass": "~1",
    "gulp": "~4",
    "gulp-autoprefixer": "~8",
    "gulp-clean-css": "~4",
    "gulp-concat": "~2",
    "gulp-csscomb": "~3",
    "gulp-filter": "~7",
    "gulp-html-replace": "~1",
    "gulp-postcss": "~8",
    "gulp-rename": "~2",
    "gulp-sass": "~5",
    "gulp-scss-lint": "~1",
    "gulp-sourcemaps": "~3",
    "gulp-uglify": "~3",
    ...
    ...
  • Update the minimum node version to 16.0 and more
      "engines": {
        "yarn": ">= 1.6",
        "node": ">= 16.0"
      },
    

Remaining tasks

  • βœ… File an issue about this project
  • βœ… Addition/Change/Update/Fix to this project
  • βœ… Testing to ensure no regression
  • βž– Automated unit/functional testing coverage
  • βœ… Developer Documentation support on feature change/addition
  • βž– User Guide Documentation support on feature change/addition
  • βœ… Accessibility and Readability
  • βœ… Code review from 1 Varbase core team member
  • βœ… Full testing and approval
  • βœ… Credit contributors
  • βœ… Review with the product owner
  • βœ… Update Release Notes and Update Helper on new feature change/addition
  • βœ… Release varbase-9.0.11 β†’ , varbase_email-9.0.2 β†’

Varbase update type

  • βœ… No Update
  • βž– Optional Update
  • βž– Forced Update
  • βž– Forced Update if Unchanged

User interface changes

  • N/A

API changes

  • N/A

Data model changes

  • N/A

Release notes snippet

πŸ“Œ Task
Status

Fixed

Version

9.0

Component

Code

Created by

πŸ‡―πŸ‡΄Jordan Rajab Natshah Jordan

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024