Iterate in each byte of a stream

Discussion in 'Learning Javascript' started by Gamefall Team, Feb 4, 2018.

    Tags:
  1. Gamefall Team

    Gamefall Team Nebula Games Leader Veteran

    Messages:
    337
    Likes Received:
    420
    Location:
    Italy
    First Language:
    Italian
    Primarily Uses:
    RMMV
    A little Node JS question, hoping that someone could help me!
    In Ruby we have a method that calls the given block of a stream once for each byte:
    https://apidock.com/ruby/IO/each_byte

    Code:
    each_byte()
    I'm creating a stream using the fs of Node.js:

    Code:
    fs.createReadStream(path)
    There is a method similar to each_byte that can I use?
     
    #1
  2. Zalerinian

    Zalerinian Jack of all Errors Veteran

    Messages:
    4,695
    Likes Received:
    921
    Location:
    The Internet.
    First Language:
    English
    Primarily Uses:
    N/A
    #2
    Gamefall Team likes this.
  3. Gamefall Team

    Gamefall Team Nebula Games Leader Veteran

    Messages:
    337
    Likes Received:
    420
    Location:
    Italy
    First Language:
    Italian
    Primarily Uses:
    RMMV
    @Zalerinian Thank you!
    I have to take a look into this :kaojoy:
     
    #3

Share This Page