Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

246
Views
class doesn't exist in type 'ILineOptions' on fabricjs

I'm trying to implement this answer on typescript, https://stackoverflow.com/a/47570603/8503317 on create Line, there is this options

var line = new fabric.Line(points, {
  strokeWidth: 2,
  fill: '#999999',
  stroke: '#999999',
  originX: 'center',
  originY: 'center',
  selectable: false,
  hasBorders: false,
  hasControls: false,
  evented: false,
  class:'line', //THIS DOESN'T EXIST ON FABRIC.LINE OPTIONS

here's the codepen

But on that codepen, it is working and don't have any error. does anyone knows why?

EDIT

Here's my reproduce https://stackblitz.com/edit/angular-ivy-bkaelf?file=src%2Fapp%2Fapp.component.ts

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Since i haven't got any solution, i fix it by manually adding class property to ILineOptions to @types/fabric. it's working now, but it's not the best solution. If you have found the best answer, please post a new answer

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!