https://discord.cloudflare.com logo
Join Discord
Powered by
# functions
  • c

    Cоlе

    01/20/2022, 8:27 AM
    yea it's usually a bit tough. with pages, you can never be 100% (stuff seems to change every day)
  • c

    Cоlе

    01/20/2022, 8:28 AM
    best advice I can give it test with wrangler@ alpha and hope for the best 😅
  • c

    Cоlе

    01/20/2022, 8:29 AM
    but yea, otherwise you can always build in a separate submodule/repo
  • c

    Cоlе

    01/20/2022, 8:32 AM
    and don't get down about it really. it's really *WONKY*™, so share some code if you're having trouble
  • v

    velvetbaldmime

    01/20/2022, 8:33 AM
    Haha, nah I'm just happy that my wonky setup works 🙂 In time to make a presentation about it. Getting it to be better is really an optional improvement for my personal project.
  • v

    velvetbaldmime

    01/20/2022, 8:34 AM
    I'm fully prepared to have troubles by utilising a) language not advertised b) build tool not advertised c) setup not advertised.
  • j

    julianbuse

    01/20/2022, 9:24 AM
    Hi,
  • j

    julianbuse

    01/20/2022, 9:25 AM
    I'm confused with durable objects in functions, as the documentation is not super thorough with this
  • j

    julianbuse

    01/20/2022, 9:25 AM
    where do I create this
  • j

    julianbuse

    01/20/2022, 9:25 AM
    in a separate cloudflare worker?
  • j

    julianbuse

    01/20/2022, 9:25 AM
    or in the same project as functions
  • s

    Stew

    01/20/2022, 9:36 AM
    https://developers.cloudflare.com/workers/learning/using-durable-objects#uploading-a-durable-object-worker Can deploy the do with wrangler
  • j

    julianbuse

    01/20/2022, 9:37 AM
    so I can't declare it in the functions project like I can with workers?
  • j

    julianbuse

    01/20/2022, 9:37 AM
    it needs to be in a separate "project"?
  • l

    LucasW

    01/20/2022, 9:52 AM
    I have filled the form in order to get an increase other the number of function calls per day, but haven't got an answer so far. Is it normal? I submitted the form two weeks ago
  • g

    Greg Brimble | Cloudflare Pages

    01/20/2022, 10:51 AM
    If you keep root as
    /
    , set the build command as
    dist.sh
    , the build output directory as
    /site
    and you modify your build script to put the functions directory into
    /functions
    rather than
    /site/functions
    , that should be everything you need
  • g

    Greg Brimble | Cloudflare Pages

    01/20/2022, 10:52 AM
    The
    functions
    directory should be in the root, not the build output directory.
  • v

    velvetbaldmime

    01/20/2022, 10:52 AM
    Ah, perhaps this is where my attempts have gone wrong. In a couple of hours I will try it + will probably have a reproducible with public github actions (if it doesn't work)
  • g

    Greg Brimble | Cloudflare Pages

    01/20/2022, 10:53 AM
    Unfortunately, yes, for now you need to deploy the DO separately. We’re planning to add automatic deployment from within your Pages project, but it’s not available yet.
  • j

    julianbuse

    01/20/2022, 10:53 AM
    ok, thanks
  • v

    velvetbaldmime

    01/21/2022, 11:31 AM
    It worked! Thank you, it's much nicer now 🙂 Not sure what I did wrong initially, but I don't care now.
  • m

    MrRaffus_

    01/21/2022, 5:27 PM
    @User Hello! sorry for the inconvenience I would like some information How can I hide the Whois on my domain on cloudflare? thanks I await response
  • w

    Walshy | Pages

    01/21/2022, 5:30 PM
    Please don't ping employees 🙂
  • w

    Walshy | Pages

    01/21/2022, 5:31 PM
    WHOIS protection is default on Cloudflare. The only thing visible is country and state/county. This is info CF is required to show
  • m

    MrRaffus_

    01/21/2022, 5:31 PM
    Yes, I would like to see nothing, what can I do?
  • w

    Walshy | Pages

    01/21/2022, 5:32 PM
    You can't hide more than is already hidden. CF is required to have that visible
  • w

    Walshy | Pages

    01/21/2022, 5:34 PM
    See more here: https://developers.cloudflare.com/registrar/why-choose-cloudflare/whois-redaction > The following fields will continue to show in WHOIS, due to ICANN policy: > Registrant state/province. > Registrant country.
  • s

    steranevdy

    01/22/2022, 10:48 AM
    how do you include workers types? I got this typescript check error
    Cannot find name 'HTMLRewriter'
  • h

    HardAtWork

    01/22/2022, 5:59 PM
    Copy code
    json
    {
      "compilerOptions": {
        "target": "ES2020",
        "module": "CommonJS",
        "lib": ["ES2020"],
        "types": ["@cloudflare/workers-types"]
      }
    }
  • r

    Rhino233

    01/22/2022, 8:16 PM
    is there a way to see the
    console.log
    in functions once it's deployed? the weird thing happened to me is sometimes it is working, but sometimes not
1...666768...392Latest