« first day (5054 days earlier)      last day (116 days later) » 

03:54
Eastern Time is my time zone
(South Carolina)
||stat
Username: Parking Master
ID: 23092266
Reputation: 616
Reputation Change Month: 0
Last Accessed: Fri Aug 16 2024 23:53:26 GMT-0400 (Eastern Daylight Time)
 
1 hour later…
05:24
anybody know how @feeds is able to programmatically upload images @user7886229
05:40
@matt I don't know about Feeds exactly. I think it doesn't even do anything, just posts in chat which uses the native embedding/onebox that chat has. But there is an endpoint to which you can upload images, if you wish - the same one used for for the "upload..." button: https://chat.stackoverflow.com/upload/image
ok i'll try messing around with the endpoint, maybe i was using cookies and fkey properly
*wasnt
Seems to return HTML code (with a script tag with JS), so you'd have to scrape out the image.
OakBot uploads images. Maybe you can ask the author how it does it. He hangs around in the C# and the Java room. I think mostly on weekdays. But is usually pretty responsive if people have questions about OakBot.
You can also see Oak's source code.
ive not written any java since the late 90's lol shame on me really
fairly similar to js
06:04
No difference at all. That's why Java was given the name - to signify it stems from JavaScript. /s
But yeah - I know Java but don't really know how to find the upload thing in the source code. Ask Michael, if you need he should point you to the right place.
im just scanning it now, i think i can see how how intelli sense might help in other languages
.. i still dont like how its always in ya face though haha it should be invoked
it looks like in java when a library is imported the methods just become available in the scope, so when i come across a method call its like which library is that in
at least in javascript, when something is imported its built off a base object, so its easy to find where the definition is
i came across this recently, and literally just crashed my browser while trying to test it
    //bad.code.com

    var a             = {};
    a.__proto__.abc   = 'xyz';

    //my.code.com

    var params    = {};
    console.log(params.abc);
when i say crashed the browser, crashed the js that was running in the tab i mean, not the browser itself
07:17
@matt just create a dockerfile for James so i can deploy him that way
 
2 hours later…
08:54
    Object.freeze({}.__proto__);

    //  bad.code.com

    var a   = {};
    a.__proto__.abc   = 'xyz';

    //  my.code.com

    var params    = {};
    console.log('params',params.abc);
@user7886229, ok, i need to go out for a walk and exercise my leg ( singular ) lol, i'll sort it out when i get back
thanks for your help this morning VLAZ
09:19
Hey. I posted a question on how to apply CSS ID's' on Next JS components. I hope anyone could answer it.

https://stackoverflow.com/questions/78881519/how-to-apply-css-id-selectors-in-next-js
@RyanBarillos Welcome to the JavaScript chat! Please review the room rules. If you have a question, just post it, and if anyone's free and interested they'll help. If you want to report an abusive user or a problem in this room, visit our meta.
Never mind. Someone has already answered it.
 
9 hours later…
18:29
@user7886229, well i came up with the following, note its doing everything as root at the moment, if it all works it can be looked into starting as a different user
the DATA_FOLDER, SOEMAIL, SOPASSWORD need to be entered in james.js
file: james.docker.file
# docker build . -f james.docker.file -t james-docker-image
# docker run -di -p 443:443 -p 2222:22 --name james-docker james-docker-image

FROM node

RUN echo "root:node" | chpasswd

RUN apt update && apt install -y openssh-server
RUN sed -i 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/' /etc/ssh/sshd_config

RUN printf  "%s\n" \
"#!/bin/bash" \
"set -e" \
"whoami" \
"echo" \
"echo 'starting ssh'" \
"service ssh start" \
"echo" \
"echo" \
"node james.js" \
"/bin/bash" \
 > 'start.sh'
file: james.js
(async()=>{

        var data_folder       = '';
        var email             = '';
        var password          = '';

        james                 = james();

        await james.download();
        await james.install();
        await james.build();
        await james.start();



function james(){
                                                                                console.clear();
  var obj   = {};

        var fs                = require('node:fs');
        var cp                = require('node:child_process');
it runs upto asking for the data_folder
you can ssh into it on port 2222, username root, password node
19:32
Hello! I'm starting a full-stack JS web app. I'm used to Ruby on Rails + React as a stack, but for this project I'm using Express for the backend. Can I please ask a couple quick newb questions?
First, I know that for client-facing TypeScript, I need to compile the project down with something like Webpack. Does server-side JS benefit from compilation as well?
Second, for an Express project, is starting the server with a command like node index.js/ts-node index.ts good enough? Or are there tools I should consider using for starting the server?
Finally, I am creating the web app as an npm mono repo with two directories, one for the Express server and one for the client-side JS. What is the typical configuration so that the server can serve the compiled and packaged frontend code? I know this isn't a quick answer, but I'm guessing there are also robust tools for this kind of job, so I'd appreciate just being pointed in the right direction!

« first day (5054 days earlier)      last day (116 days later) »