scttcper / tinycolor

🎨 Color manipulation and conversion

Home Page:https://tinycolor.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Compatible with IE11 ?

PooLP opened this issue · comments

Hi,
I have tested your lib on SPFx component (Microsoft Framework for Sharepoint : https://docs.microsoft.com/en-us/sharepoint/dev/spfx/sharepoint-framework-overview)

Your lib work perfectly in all modern browser, but i have error with IE11 : (Characters expected on Transform method apparently)

Your lib is compatible with IE11 ?

Thanks

How are you using the library? or how is it being imported

Hi,
I'm use this lib in a component for Sharepoint Solution (SPFx).
this Is a React + Typescirpt context and i can't not modify Webpack config. (React 15, Webpack 2, TS 2.4.2) and the imposed tsconfig is :

{
  "compilerOptions": {
    "target": "es5",
    "forceConsistentCasingInFileNames": true,
    "module": "esnext",
    "moduleResolution": "node",
    "jsx": "react",
    "declaration": true,
    "sourceMap": true,
    "experimentalDecorators": true,
    "skipLibCheck": true,
    "typeRoots": [
      "./node_modules/@types",
      "./node_modules/@microsoft"
    ],
    "types": [
      "es6-promise",
      "webpack-env"
    ],
    "lib": [
      "es5",
      "dom",
      "es2015.collection"
    ]
  }
}

the import is normal import (i thinks ^^)
import { TinyColor } from '@ctrl/tinycolor';

I a reverted on old lib TinyColor2 and it's work correctly on IE11 (but, it's IE 💩).

That's why I ask the question, Is your lib compatible with IE11?

Thanks

@PooLP For me, with version 2.0.1, IE raised the error:
SCRIPT1003: Expected ':'
but, verion 2.1.0 seems to work :)

Okay great. I made some changes to how it’s built for 2.1.0. I don’t have an IE virtualbox setup at the moment to try it

It's ok for me, it work perfectly !!!

Another question, are you going to distribute this lib on cdn? (on cdnjs.com it's old version)

Thanks

right now the plan is to get this merged back into the official tinycolor2 https://github.com/bgrins/TinyColor and then maybe. still working with bgrins on that.

unpkg has it though

https://unpkg.com/@ctrl/tinycolor@2.1.0/bundles/tinycolor.umd.min.js

Exact same issue with 3.1.1. Does IE11 support has been dropped with the 3.x branch?