« first day (2582 days earlier)      last day (2589 days later) » 

08:13
Heyo
I have been using webpack for the past 6 months and never had the need for gulp anymore, I feel kinda sad about that. Is there still a use-case for Gulp or has webpack taken over everything? I know one is a task runner the other is a bundling tool. But all I used gulp for was to watch my files, transform and bundle them, and move them into the dist folder anyways. Who here still uses gulp and what for?
anything that doesnt require making a bundle, for example :)
Hehe yeah I suppose I understand that.. :)
I use gulp all the time, for my node backend apps for example
What do you do with gulp there?
I just need some real-life examples to make it click.
08:32
one of the most basic gulp scripts I use is this:
const gulp = require('gulp');
const ts = require('gulp-typescript');

// pull in the project Typescript config
const tsProject = ts.createProject('tsconfig.json');

//task to be run when the watcher detects changes
gulp.task('scripts', () => {
  const tsResult = tsProject.src()
  .pipe(tsProject());
  return tsResult.js.pipe(gulp.dest('dist'));
});

//set up a watcher to watch over changes
gulp.task('watch', ['scripts'], () => {
  gulp.watch('**/*.ts', ['scripts']);
});

gulp.task('default', ['watch']);
for some others, I will have more tasks, for ex. copying assets to dist
this one just transpiles typescript
cc @Schoening
document.querySelector("tr[aria-label]") ==> I'm trying to specify a value for the attribute I'm selecting on (a value which need to be variable) in a selenium Java test, but I can't get it to work
 <tr class="dijitReset dijitMenuItem" data-dojo-attach-point="focusNode" role="option" tabindex="-1" id="dijit_MenuItem_1" aria-label="CONTBUILD " aria-disabled="false" widgetid="dijit_MenuItem_1" style="user-select: none;">...
 </tr>
That's the element I'm trying to select, and I would like to select it through the aria-label
mild truncation of the things between
I got 6 of those tr aria-label tags on the same page, so I need to select this particular one
oh, there's a space at the end
...
@KamilSolecki I am working with TypeScript and that is what I do using Webpack actually. I got a input and output dir and let webpack watch for changes.
user6105689
Hi there anyone for angular?
@Schoening What about the server? Do you just run it using ts-node?
^ ?
(i second the question)
user6105689
08:39
I've deployed app on a shared hosting. Is possibile to add page or edit file on a --prod version of angula app
user6105689
?
ugh depends
how does the prod version look like
is it bundled?
Last time I played around with it I did, yeah. But maybe that is a good point. I don't know.. I use TypeScript for front-end and let the C# guys do the server where I work.
Fair enough
some people like using webpack + gulp together too
still, all is personal preference
user6105689
08:40
it a minified version
then you just answered your question :D
user6105689
with a bunch of bundle.js and one index.html
And you don't have the source?
user6105689
and is possibile deploy a version editable for dev...?
will need to replace the bundles with the new ones
@Sago sure, but...why
08:42
@Sago Why would you do that
I am glad to hear gulp still is around. I find webpack pretty daunting at times. And I wanted to hack together a NativeScript project and with gulp I can sort of work in one folder, pipe it into the other, do webpack stuff there.
Do your modifications locally
then push to prod
Gulp is a dream come true
user6105689
I need to retrive some data from a site there yet on a shared hosting
08:42
^^
Fuck people that still use grunt
wow Ben says wise things today
i agree with all
I tried grunt once
Kamil sucks
user6105689
I need to implement Angular to thi site
Every since I got my first real job in enterprise I have become a little paranoid with tech that might get outdated. Which is idiotic since enterprise code ofc gets outdated.
08:43
Ben you infidel
I feel webpack looks like grunt lol....
@Sago be more precise, you aren't making much sense
@Schoening You're working with JavaScript, increase this tenfold
user6105689
I have mysite.com and I need to create a backend page for admin that get some data from the site (on click event, online users, geolocalization and more....)
then make a new webapp
user6105689
08:46
and add some api from google and other services...How can i get this datas from locally?
What I meant to say is that its expected and OK to have some legacy code on the backend. I just feel like its not allowed on the font-end. Idk if thats just my brain tho @BenFortune I think I have been too much on medium!
oddest thing is that at a given moment, people with a bicycle stops there waiting when it is open. Yet there is a pedestrian bridge 10m left of it ...
@Schoening Haha, depends on your browser support really.
If you're enterprise, I'm guessing you want some old IE support. Meaning legacy code is pretty much a necessity
We cut off at IE9 fortunately
08:49
@Sago so basically you wanna create a backend 'data proxy' that will aggregate data from all services and expose them to your webapp (on like, a websocket)
Anything < IE11 is legacy :P
Haha :D
user6105689
@kam you say right
user6105689
@KamilSolecki you say right
@Sago Press up to edit your last messages
08:51
So.. if gulp + webpack does exactly what I need... then you are saying I don't need to listen to Hipster_92341 article saying that I need to move to <insert new tool name here> ? :p
so, what is the problem you are facing? @Sago
If you're not doing back-end JavaScript, I'd say webpack is enough with ts-loader
user6105689
@BenFortune sorry, thanks for suggestion
user6105689
@KamilSolecki I would an Angular online Developing env, so i can add and edit all directly from my ftp and my hosting
oh dear
user6105689
08:57
I'm saying bullshit?
hello i was wondering if an open-source javascript library exists similar to the following: imgur.com/k1OEEmH

this is a scheduling widget where u can pick from a tutor's available times (denoted in green)
Make one
i feel like this is a generic plugin
that exists somewhere
that i just don't know the name of
it's a calendar
Just search "calendar javascript"
@Sago why not develop locally (using source control if multiple machines) and push to prod when needed?
why would you want an in-development app to be available online?
user6105689
09:00
@KamilSolecki only beacuse I'm not working on a single pc, and I want to dev from everywhere
see my first point
source control is your friend
make use of it
user6105689
using source control...ok thanks a lot...I'm going to discover it....
user6105689
thanks
whispers git
user6105689
ahahhahahahhaahhahah right....thanks a lot
09:03
no problemo.
user8639911
Is there a way with fabricjs to move object in 2 differents canvas ?
Also, I said > source control if multiple machines. Was a mistake. Just use source control all the time.
user8639911
Exemple : moving rectangle in canvas A would move rectangle in canvas B
@EyRaG_ Yeah, just track the events in one and replicate it in the other
user8639911
tried to do it in so many way . couldn't make it work ..
09:10
Got an example?
user8639911
Actually when i move my background image (not set as background but as image object) all rectangle that i drawed is moving with it .
user8639911
and i tried to apply this to the image and rectangle of the second canvas
user8639911
 myImg.on('mousedown', function() {

        myImg.centerPt = this.getCenterPoint();
            canvas.forEachObject(function(obj) {
                obj.origPose = new fabric.Point(obj.left, obj.top);

            })
        })
        myImg.on('mouseup', function() {
            delete this.centerPt;
            canvas.forEachObject(function(obj) {
                delete obj.origPose;
            })
            img1.setCoords();
            ImgTop = img1.top;
            ImgLeft = img1.left;
user8639911
i tried to apply this to canvas2
Make a fiddle
user8639911
09:12
i'll do , but my code is huge x) and a bit in disorder
damn I would've thought facebook has a smart algorithm for cropping the product feed photos
it doesnt.
seems it is not only cropping but cutting content first, then cropping
can you not configure it to crop only ?
o/
@KarelG problem is
photos are not square
facebooks' ones are (almost)
also, no configs as far as I can tell
but am searching
oh wait there is setttings
09:27
Hey is here someone??
@NirikshanBbusal Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
Thanks @CapricaSix...
I am running out of problem with shadow dom can any one help me??
user8639911
@BenFortune Here , can't make the fiddle work -- jsfiddle.net/Lfhrhj6b/31/#&togetherjs=v3N0VsqJMk
> Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
@NirikshanBbusal
I can't get you @Neoares would you never mind to say it in more understandable way
09:35
you don't need to ask if you can ask
just ask your question
user8639911
@BenFortune Ben ?
@EyRaG_ I don't get what you're trying to do. When you move it in one canvas, you want it to move in the second canvas?
user8639911
@BenFortune yes but i only want it to happen on the image (works in my code) actually when dragging the image it move all the object in same canvas . and i want to to it on both canvas
user8639911
When i drag image , both image and all rectangle will move with
just keep a collection of your canvas items and get your canvas object that you want to transfer over?
09:47
scontent.fktm5-1.fna.fbcdn.net/v/t31.0-8/fr/cp0/e15/q65/… please have a look at this image and try to find what's wrong..???
user8639911
@KarelG How
user8639911
i'm almost doing it for my first canvas but can't apply it to the second .
you know already how to obtain a ref to a canvas object: var img1 = myImg
user8639911
You can speak on fiddle chat
I'm at work atm, cannot help directly. But to complete on what I said: you also know when an image is being dragged. Now, check when the image is being dragged out the canvas area.
if that happens, remove the image from the canvas window and put the object in the new canvas window
simply said
user8639911
09:52
That's not what i want
yes, you can expand on that ...
user8639911
When ImgX on canvas 1 is moving , all object on canvas1 and canvas2 are moving .
When ImgY on canvas2 is moving , all object on canvas1 and canvas2 are moving
when dragging over the image, drag also the objects that got hooked with that image
user8639911
But actually : i can only do that : when ImgX on canvas 1 is moving all object on canvas1 are moving
user8639911
and i don't know how to interract with Canvas2
09:57
@Zirak damn son. That's stunning
var canvas is your canvas. Put another canvas and call it canvas2. Keep both fields globally. Then you can simply interact with other canvas by using that variable
user8639911
@KarelG did you see my fiddle ? with the move:up/down and moving event on Img , i tried to copy/past the canvas.foreach bla bla bla action and try with Canvas2.foreach
user8639911
but don't work.
@EyRaG_ Something like this? jsfiddle.net/Lfhrhj6b/38
user8639911
@BenFortune Dammit you're genius !
user8639911
10:02
is it possible to the the same with img2 ?
It's even easier if you want either to move regardless
user8639911
what do you mean ?
wait img2?
user8639911
On your fiddle if i move Img on SecondCanvas
user8639911
it don't move img on canvas
user8639911
10:04
how can i edit your fiddle to make this work
Oh, yeah that's what I was talking about
user8639911
How can i do that xP ?
@phenomnomnominal <3
user8639911
@BenFortune i'll need to merge your code with mine because your fiddle doesn't handle rectangle drawn on the canvas .
Should work with all objects in the canvas
user8639911
@BenFortune why when adding a rectangle everything broke up jsfiddle.net/Lfhrhj6b/45
-1
Q: how to set text bold using fs writer in node.js?

Balaji KRHow to set bold text while using fs to save the file in node.js? I tried this code, its doesn't work. csvify.rowFromArray is just a function just check the array is string or not var myArray = ['Student Name', 'Father Name', 'EmailID']; myArray[0].fontWeight = 800; myArray[1].fontWeight = 800; ...

What the fuck lmfao
@EyRaG_ Check your console
user8639911
Ahahah
user8639911
kill me please
Also if you want to synchronize it, you'll need to add it to both canvases
user8639911
10:25
@BenFortune as i said , rectangle aren't moving with the image
@BenFortune hehe
user8639911
@BenFortune did it
@EyRaG_ You're locking the movement...
Are you even reading what you're coding
> Just write harder
user8639911
10:27
@BenFortune on my own coding i'm locking their movement but they still move
If you want them to move, don't lock the movement
What aren't you getting?
user8639911
@BenFortune With this piece of code , my rectangle move with the image
user8639911
 myImg.on('mousedown', function() {

        myImg.centerPt = this.getCenterPoint();
            canvas.forEachObject(function(obj) {
                obj.origPose = new fabric.Point(obj.left, obj.top);

            })
        })
        myImg.on('mouseup', function() {
            delete this.centerPt;
            canvas.forEachObject(function(obj) {
                delete obj.origPose;
            })
            img1.setCoords();
            ImgTop = img1.top;
            ImgLeft = img1.left;
user8639911
Event with locked movement
user8639911
10:28
try it by yourself
user8639911
And if I unlock movement user will be able to drag the rectangle and that's not what I want
10:49
@BenFortune nfs payback is out today
i gotta get home early
@KamilSolecki oh shit, destiny 2 took my budget for this month :(
@EyRaG_ Are you just wanting to pan...?
@BenFortune how fun is it?
@KamilSolecki It's pretty good, the raids are hard as fuck if you aren't coordinated
tbh I never played destiny
I did play wow and mythic raids tho :P
which are hard af as well.
@KamilSolecki Can you tell me later if is it worth to get?
10:59
sure thing
will start gaming today
user8639911
@BenFortune when the image move. All the object (rectangle) move with it. The both canvas will contain rectangle but in different position.
Oh, I broke my controller too
@KamilSolecki did a +16 the other day

« first day (2582 days earlier)      last day (2589 days later) »